Best Python code snippet using avocado_python
test_job.py
Source:test_job.py  
...176        self.job.run()177        self.assertNotEqual(self.job.time_start, -1)178        self.assertNotEqual(self.job.time_end, -1)179        self.assertNotEqual(self.job.time_elapsed, -1)180    def test_job_self_account_time(self):181        args = argparse.Namespace(base_logdir=self.tmpdir)182        self.job = job.Job(args)183        self.job.setup()184        self.job.time_start = 10.0185        self.job.run()186        self.job.time_end = 20.0187        # forcing a different value to check if it's not being188        # calculated when time_start or time_end are manually set189        self.job.time_elapsed = 100.0190        self.assertEqual(self.job.time_start, 10.0)191        self.assertEqual(self.job.time_end, 20.0)192        self.assertEqual(self.job.time_elapsed, 100.0)193    def test_job_dryrun_no_unique_job_id(self):194        args = argparse.Namespace(dry_run=True, base_logdir=self.tmpdir)...Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!
