You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I came over this issue in the discussion of #3428: Use gitversion when promoting builds across environments. The scenario is quite simple that the user wants to tag a commit in one branch (or even with merging) with not only the same label name. If the branch is not labeled and the name is set to null then I would expect that all pre-release tags are considered. The other problem here is that the system behaves different if it is used the first time where the fallback version strategy applies.
Expected Behavior
[TestCase(1)][TestCase(2)]publicvoidExpectedBehavior(longpatchNumber){varconfiguration=GitHubFlowConfigurationBuilder.New.WithLabel(null).WithBranch("main", branchBuilder =>branchBuilder.WithLabel(null).WithIncrement(IncrementStrategy.Patch)).Build();usingvarfixture=newEmptyRepositoryFixture("main");fixture.MakeACommit();// ✅ succeeds as expectedfixture.AssertFullSemver("0.0.1+1",configuration);fixture.ApplyTag($"0.0.{patchNumber}-alpha.1");// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}-alpha.1",configuration);fixture.MakeACommit();// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}-alpha.2+1",configuration);fixture.MakeACommit();// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}-alpha.2+2",configuration);fixture.MakeATaggedCommit($"0.0.{patchNumber}-beta.1");// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}-beta.1",configuration);fixture.MakeACommit();// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}-beta.2+1",configuration);fixture.MakeATaggedCommit($"0.0.{patchNumber}-beta.2");// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}-beta.2",configuration);fixture.MakeACommit();// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}-beta.3+1",configuration);fixture.ApplyTag($"0.0.{patchNumber}");// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber}",configuration);fixture.MakeACommit();// ✅ succeeds as expectedfixture.AssertFullSemver($"0.0.{patchNumber+1}+1",configuration);}
Describe the bug
I came over this issue in the discussion of #3428: Use gitversion when promoting builds across environments. The scenario is quite simple that the user wants to tag a commit in one branch (or even with merging) with not only the same label name. If the branch is not labeled and the name is set to null then I would expect that all pre-release tags are considered. The other problem here is that the system behaves different if it is used the first time where the fallback version strategy applies.
Expected Behavior
Actual Behavior
Possible Fix
NextVersionCalculator::FindVersion
NextVersionCalculator::GetNextVersions
Steps to Reproduce
Please see the integration tests above.
Context
Your Environment
I have used the 6.0.0-beta.1 version
The text was updated successfully, but these errors were encountered: