Skip to content

Commit

Permalink
Added a simple semanticVersion to string test
Browse files Browse the repository at this point in the history
  • Loading branch information
EwyBoy committed Jan 5, 2024
1 parent 3562ab3 commit 76b1da7
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/SpaceWarpTest/API/Versions/SemanticVersionTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -174,4 +174,14 @@ public bool SemanticVersion_OperatorGreaterThanOrEqual_ComparesVersions(string v

return semanticVersion1 >= semanticVersion2;
}

[TestCase("1.2.3", ExpectedResult = "1.2.3")]
[TestCase("1.2.3-alpha", ExpectedResult = "1.2.3-alpha")]
[TestCase("1.2.3-alpha+build1", ExpectedResult = "1.2.3-alpha+build1")]
public string SemanticVersion_ToString_ReturnsVersionString(string version)
{
var semanticVersion = new SemanticVersion(version);
return semanticVersion.ToString();
}

}

0 comments on commit 76b1da7

Please sign in to comment.