def test_submit_ret_type(self): # condor_submit format: (3 lines) # Submitting job(s). # Logging submit event(s). # 1 job(s) submitted to cluster 1024. cc = CondorClient() cc._shell_submit = Mock(return_value=('', '', '1 job(s) submitted to cluster 1024.')) self.assertEqual(cc.submit('file'), ('1', '1024'))
def test_submit_shell_call(self): cc = CondorClient() cc._shell_submit = Mock(return_value=('', '', '1 job, cluster 1024.')) cc.submit('file') self.assertTrue(cc._shell_submit.called, 'shell_submit() not called')