def test_install_python_module_locally_raises_exception_on_failure( self, *args, **kwargs): with self.assertRaises(SystemExit) as cm: pkg.install_python_module_locally('fake-python-module') self.assertEqual(cm.exception.code, 1)
def test_install_python_module_locally_returns_True_on_success(self, *args, **kwargs): self.assertTrue(pkg.install_python_module_locally('appdirs'))
def test_install_python_module_locally_installs_module(self, *args, **kwargs): pkg.install_python_module_locally('appdirs') self.assertTrue('appdirs' in local('pip list', capture=True))
def test_install_python_module_locally_raises_exception_on_failure( self, *args, **kwargs): with self.assertRaises(SystemExit) as cm: pkg.install_python_module_locally('fake-python-module') self.assertEqual(cm.exception.code, 1)
def test_install_python_module_locally_returns_True_on_success( self, *args, **kwargs): self.assertTrue(pkg.install_python_module_locally('appdirs'))
def test_install_python_module_locally_installs_module( self, *args, **kwargs): pkg.install_python_module_locally('appdirs') self.assertTrue('appdirs' in local('pip list', capture=True))