generated from aboutcode-org/skeleton
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Keshav Priyadarshi <git@keshav.space>
- Loading branch information
1 parent
08959e2
commit 19de006
Showing
3 changed files
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# | ||
# Copyright (c) nexB Inc. and others. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
# Visit https://aboutcode.org and https://github.com/nexB/univers for support and download. | ||
|
||
from unittest import TestCase | ||
|
||
import semver | ||
|
||
|
||
class TestPythonSemver(TestCase): | ||
def test_semver_hash(self): | ||
# python-semver doesn't consider build while hashing | ||
vers1 = semver.VersionInfo.parse("1.2.3") | ||
vers2 = semver.VersionInfo.parse("1.2.3+1") | ||
assert hash(vers1) == hash(vers2) |