Ejemplo n.º 1
0
 def test_shutdown_handler(self):
     with patch('sys.exit') as exit:
         _shutdown_cleanup(15, Mock())
         self.assertTrue(exit.called)
         self.assertEqual(os.WTERMSIG(exit.call_args[0][0]), 15)
Ejemplo n.º 2
0
 def test_shutdown_handler(self):
     with patch('sys.exit') as exit:
         _shutdown_cleanup(15, Mock())
         exit.assert_called()
         assert os.WTERMSIG(exit.call_args[0][0]) == 15
Ejemplo n.º 3
0
 def test_shutdown_handler(self):
     with patch('sys.exit') as exit:
         _shutdown_cleanup(15, Mock())
         self.assertTrue(exit.called)
         self.assertEqual(os.WTERMSIG(exit.call_args[0][0]), 15)
Ejemplo n.º 4
0
 def test_shutdown_handler(self):
     with patch('sys.exit') as exit:
         _shutdown_cleanup(15, Mock())
         exit.assert_called()
         assert os.WTERMSIG(exit.call_args[0][0]) == 15