Exemple #1
0
def test_pep440_version_fallback_cmp():
    with pytest.raises(NotImplementedError):
        PEP440VersionFallback.cmp(
            PEP440VersionFallback('1.2.3'),
            PEP440VersionFallback('1.2.3')
        )
Exemple #2
0
def test_pep440_version_fallback_init_valid(version):
    PEP440VersionFallback(version)
Exemple #3
0
def test_pep440_version_fallback_api(api, version):
    v1 = PEP440VersionFallback(version)
    v2 = PEP440Version(version)
    assert getattr(v1, api) == getattr(v2, api)
Exemple #4
0
def test_pep440_version_fallback_init_invalid(version):
    with pytest.raises(InvalidVersionError):
        PEP440VersionFallback(version)