Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add possibility to delete branch Model Condition #70

Merged
merged 27 commits into from
Jun 2, 2017

Conversation

j0nathan33
Copy link
Contributor

No description provided.

j0nathan33 added 21 commits May 23, 2017 09:28
 Conflicts:
	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiMockTest.java
…o branchModel-list

# Conflicts:
#	src/main/java/com/cdancy/bitbucket/rest/fallbacks/BitbucketFallbacks.java
# Conflicts:
#	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiLiveTest.java
# Conflicts:
#	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiLiveTest.java
# Conflicts:
#	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiLiveTest.java
…o branchModel-Update

# Conflicts:
#	src/main/java/com/cdancy/bitbucket/rest/features/BranchApi.java
#	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiLiveTest.java
#	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiMockTest.java
@cdancy
Copy link
Owner

cdancy commented May 26, 2017

Rebase off of master to resolve conflicts?

BranchModelConfiguration branchModelConfiguration = api().updateModelConfiguration(projectKey, repoKey, configuration);
assertThat(branchModelConfiguration).isNotNull();
assertThat(branchModelConfiguration.errors().isEmpty()).isTrue();
assertThat(branchModelConfiguration.development().refId()).isNotNull();
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed this check in master as it was null for me on my version of Bitbucket.

}

private void checkDefaultBranchConfiguration() {
assertThat(branchModelConfiguration).isNotNull();
assertThat(branchModelConfiguration.errors().isEmpty()).isTrue();
assertThat(branchModelConfiguration.development().refId()).isNotNull();
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed this check as well as it was null for me.

@Path("/branch-utils/{jclouds.api-version}/projects/{project}/repos/{repo}/branchmodel/configuration")
@Fallback(BitbucketFallbacks.FalseOnError.class)
@DELETE
boolean deleteModelConfiguration(@PathParam("project") String project,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@documentation annotation for this? Searched online and couldn't find anything

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, this endpoint isn't in documentation.

Source : https://jira.atlassian.com/browse/BSERV-5411

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@j0nathan33 can you add the Documentation annotation and use that jira ISSUE?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, I will do it.

j0nathan33 and others added 4 commits May 29, 2017 07:56
…o branchModel-delete

# Conflicts:
#	src/main/java/com/cdancy/bitbucket/rest/features/BranchApi.java
#	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiLiveTest.java
#	src/test/java/com/cdancy/bitbucket/rest/features/BranchApiMockTest.java
.gitattributes Outdated
@@ -1,6 +1,6 @@
# Handle line endings automatically for files detected as text
# and leave all files detected as binary untouched.
* text=auto
* text=lf
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we back this out and open a separate PR for it if you truly want to change it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I will do it

@cdancy cdancy self-assigned this May 30, 2017
@cdancy cdancy added this to the v0.0.16 milestone May 30, 2017
@cdancy cdancy merged commit a441fe9 into cdancy:master Jun 2, 2017
@cdancy
Copy link
Owner

cdancy commented Jun 2, 2017

@j0nathan33 merged this PR with various fixes to account for proper integration test support now working OOTB. For future PR's, and assuming you have a bitbucket instance, simply running ./gradlew integTest will now work for all live tests (also assumes you've set the necessary properties).

@j0nathan33 j0nathan33 deleted the branchModel-delete branch June 5, 2017 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants