def test_python26dbg(self): i = Interpreter('python2.6-dbg') self.assertEqual(i.soabi(), '') self.assertIsNone(i.check_extname('foo_d.so')) self.assertEqual(i.check_extname('foo.so'), 'foo_d.so') self.assertEqual(i.check_extname('foo/bar/bazmodule.so'), 'foo/bar/bazmodule_d.so')
def test_python32dbg(self): i = Interpreter('python3.2-dbg') self.assertEqual(i.soabi(), 'cpython-32dmu') self.assertEqual(i.check_extname('foo.so'), r'foo.cpython-32dmu.so') self.assertIsNone(i.check_extname('foo.cpython-33m.so')) # different version self.assertIsNone(i.check_extname('foo.cpython-32dmu-OTHER.so')) # different architecture self.assertIsNone(i.check_extname('foo.abi3.so')) self.assertEqual(i.check_extname('foo/bar/bazmodule.so'), r'foo/bar/bazmodule.cpython-32dmu.so')
def test_python27dbg(self): i = Interpreter('python2.7-dbg') self.assertEqual(i.soabi(), '') self.assertEqual(i.check_extname('foo.so'), 'foo.MYARCH_d.so') self.assertEqual(i.check_extname('foo_d.so'), 'foo.MYARCH_d.so') self.assertIsNone(i.check_extname('foo.MYARCH_d.so')) self.assertIsNone(i.check_extname('foo.OTHER_d.so')) # different architecture self.assertEqual(i.check_extname('foo/bar/bazmodule.so'), 'foo/bar/bazmodule.MYARCH_d.so')
def test_python34dbg(self): i = Interpreter('python3.4-dbg') self.assertEqual(i.soabi(), 'cpython-34dm') self.assertEqual(i.check_extname('foo.so'), r'foo.cpython-34dm-MYARCH.so') self.assertIsNone(i.check_extname('foo.cpython-32m.so')) # different version self.assertIsNone(i.check_extname('foo.cpython-34m-OTHER.so')) # different architecture self.assertIsNone(i.check_extname('foo.abi3.so')) self.assertEqual(i.check_extname('foo/bar/bazmodule.so'), r'foo/bar/baz.cpython-34dm-MYARCH.so')
def test_python27dbg(self): i = Interpreter('python2.7-dbg') self.assertEqual(i.soabi(), '') self.assertEqual(i.check_extname('foo.so'), 'foo.MYARCH_d.so') self.assertEqual(i.check_extname('foo_d.so'), 'foo.MYARCH_d.so') self.assertIsNone(i.check_extname('foo.MYARCH_d.so')) self.assertIsNone( i.check_extname('foo.OTHER_d.so')) # different architecture self.assertEqual(i.check_extname('foo/bar/bazmodule.so'), 'foo/bar/baz.MYARCH_d.so')
def test_python32(self): i = Interpreter('python3.2') self.assertEqual(i.soabi(), 'cpython-32mu') self.assertEqual(i.check_extname('foo.so'), r'foo.cpython-32mu.so') self.assertIsNone( i.check_extname('foo.cpython-33m.so')) # different version self.assertIsNone(i.check_extname( 'foo.cpython-32mu-OTHER.so')) # different architecture self.assertIsNone(i.check_extname('foo.abi3.so')) self.assertEqual(i.check_extname('foo/bar/bazmodule.so'), r'foo/bar/bazmodule.cpython-32mu.so')
def test_python36dbg(self): i = Interpreter('python3.6-dbg') self.assertEqual(i.soabi(), 'cpython-36dm') self.assertEqual(i.check_extname('foo.so'), r'foo.cpython-36dm-MYARCH.so') self.assertIsNone( i.check_extname('foo.cpython-32m.so')) # different version self.assertIsNone(i.check_extname( 'foo.cpython-36m-OTHER.so')) # different architecture self.assertIsNone(i.check_extname('foo.abi3.so')) self.assertEqual(i.check_extname('foo/bar/bazmodule.so'), r'foo/bar/baz.cpython-36dm-MYARCH.so')
def test_python31dbg(self): i = Interpreter('python3.1-dbg') self.assertEqual(i.soabi(), '') self.assertIsNone(i.check_extname('foo.so')) self.assertIsNone(i.check_extname('foo.abi3.so')) self.assertIsNone(i.check_extname('foo/bar/bazmodule.so'))