def test_get_rexes_names_versions(self): self.assertEqual( avail_wheels.get_rexes( product(["numpy", "TORCH_CPU"], ["1.2", "0.4*"])), self.rexes_compile(patterns=[ "numpy-1.2[-+]*.whl", "numpy-0.4*[-+]*.whl", "TORCH_CPU-1.2[-+]*.whl", "TORCH_CPU-0.4*[-+]*.whl" ]))
def test_get_rexes_names_star(self): self.assertEqual( avail_wheels.get_rexes(product(["numpy", "TORCH_CPU"], ['*'])), self.rexes_compile( patterns=["numpy-*[-+]*.whl", "TORCH_CPU-*[-+]*.whl"]))
def test_get_rexes_star_versions(self): self.assertEqual( avail_wheels.get_rexes(product(['*'], ['1.2', '0.4.*'])), self.rexes_compile( patterns=["*-1.2[-+]*.whl", "*-0.4.*[-+]*.whl"]))
def test_get_rexes_name_version(self): self.assertEqual( avail_wheels.get_rexes(product(["numpy", "NUMPY"], ["1.2"])), self.rexes_compile( patterns=["numpy-1.2[-+]*.whl", "NUMPY-1.2[-+]*.whl"]))
def test_get_rexes_star_star(self): self.assertEqual(avail_wheels.get_rexes(product(['*'], ['*'])), self.rexes_compile(patterns=["*-*[-+]*.whl"]))