Exemple #1
0
 def test_not_configured(self):
     from jove.scripts.utils import get_pids_dir
     args = mock.Mock()
     args.app.registry.settings.get.return_value = None
     self.assertEqual(get_pids_dir(args), '/virtual/env/var/pids')
Exemple #2
0
 def test_configured(self):
     from jove.scripts.utils import get_pids_dir
     args = mock.Mock()
     args.app.registry.settings.get.return_value = 'myvar'
     self.assertEqual(get_pids_dir(args), 'myvar')
     args.app.registry.settings.get.assert_called_once_with('pids')