@Test(dataProvider = "imageNameAndExpectedBranch") public void testGetBranchNameForImageTagCombos(String imageName, String imageTag, String expectedResult) { assertEquals(new GitForkBranch(imageName, imageTag, "").getBranchName(), expectedResult); }
public String getBranchName() { if (this.imageTag == null || this.imageTag.trim().isEmpty()) { return this.branchPrefix; } else { return this.branchPrefix + "-" + this.imageTag; } }
GitForkBranch { public String getBranchName() { if (this.imageTag == null || this.imageTag.trim().isEmpty()) { return this.branchPrefix; } else { return this.branchPrefix + "-" + this.imageTag; } } }
GitForkBranch { public String getBranchName() { if (this.imageTag == null || this.imageTag.trim().isEmpty()) { return this.branchPrefix; } else { return this.branchPrefix + "-" + this.imageTag; } } GitForkBranch(String imageName, String imageTag, String specifiedBranch); }
GitForkBranch { public String getBranchName() { if (this.imageTag == null || this.imageTag.trim().isEmpty()) { return this.branchPrefix; } else { return this.branchPrefix + "-" + this.imageTag; } } GitForkBranch(String imageName, String imageTag, String specifiedBranch); boolean isSameBranchOrHasImageNamePrefix(String branchName); boolean useSpecifiedBranchOverride(); String getBranchName(); String getImageName(); String getImageTag(); }
GitForkBranch { public String getBranchName() { if (this.imageTag == null || this.imageTag.trim().isEmpty()) { return this.branchPrefix; } else { return this.branchPrefix + "-" + this.imageTag; } } GitForkBranch(String imageName, String imageTag, String specifiedBranch); boolean isSameBranchOrHasImageNamePrefix(String branchName); boolean useSpecifiedBranchOverride(); String getBranchName(); String getImageName(); String getImageTag();  }