Ejemplo n.º 1
0
 def test_not_supported_version(self):
     """
     Test unsupported wheel is known to be unsupported
     """
     w = wheel.Wheel('simple-0.1-py2-none-any.whl')
     assert not w.supported(tags=[('py1', 'none', 'any')])
Ejemplo n.º 2
0
 def test_supported_single_version(self):
     """
     Test single-version wheel is known to be supported
     """
     w = wheel.Wheel('simple-0.1-py2-none-any.whl')
     assert w.supported(tags=[('py2', 'none', 'any')])
Ejemplo n.º 3
0
 def test_supported_multi_version(self):
     """
     Test multi-version wheel is known to be supported
     """
     w = wheel.Wheel('simple-0.1-py2.py3-none-any.whl')
     assert w.supported(tags=[('py3', 'none', 'any')])
Ejemplo n.º 4
0
 def test_invalid_filename_raises(self):
     with pytest.raises(InvalidWheelFilename):
         wheel.Wheel('invalid.whl')
Ejemplo n.º 5
0
 def test_missing_version_raises(self):
     with pytest.raises(InvalidWheelFilename):
         wheel.Wheel('Cython-cp27-none-linux_x86_64.whl')
Ejemplo n.º 6
0
 def test_single_digit_version(self):
     w = wheel.Wheel('simple-1-py2-none-any.whl')
     assert w.version == '1'
Ejemplo n.º 7
0
 def test_support_index_min_none(self):
     """
     Test `support_index_min` returns None, when wheel not supported
     """
     w = wheel.Wheel('simple-0.1-py2-none-any.whl')
     assert w.support_index_min(tags=[]) is None
Ejemplo n.º 8
0
 def test_non_pep440_version(self):
     w = wheel.Wheel('simple-_invalid_-py2-none-any.whl')
     assert w.version == '-invalid-'