Example #1
0
 def test_main_default_per_author(
         self, mock_desc, update_desc, stop_build, get_json):
     args = [
         '-t', self.api_key,
         '-u', self.user,
         '-j', self.job_url,
         '--log-level', 'INFO',
     ]
     deduper_main(args)
     get_json.assert_called_once_with()
     stop_build.assert_called_once_with(2)
     update_desc.assert_called_once_with(2, mock_desc())
Example #2
0
 def test_main_one_per_author(self, update_desc, stop_build, get_json):
     args = [
         '-t', self.api_key,
         '-u', self.user,
         '-j', self.job_url,
         '--log-level', 'INFO',
         '--one-per-author'
     ]
     deduper_main(args)
     get_json.assert_called_once_with()
     self.assertFalse(stop_build.called)
     self.assertFalse(update_desc.called)