Skip to content

Commit 1ee56af

Browse files
committed
testsuite: rename variable for consistency
Problem: A test in python/t0010-job.py uses the variable "meta" to describe the data returned from a job-list call. However, we use the term "info" more often due to the JobInfo class. Rename the "meta" variable to "info".
1 parent 7129553 commit 1ee56af

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

t/python/t0010-job.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -689,8 +689,8 @@ def cancel_on_start(future, jobid):
689689
def test_33_get_job(self):
690690
self.sleep_jobspec = JobspecV1.from_command(["sleep", "5"])
691691
jobid = job.submit(self.fh, self.sleep_jobspec)
692-
meta = job.get_job(self.fh, jobid)
693-
self.assertIsInstance(meta, dict)
692+
info = job.get_job(self.fh, jobid)
693+
self.assertIsInstance(info, dict)
694694
for key in [
695695
"id",
696696
"userid",
@@ -712,17 +712,17 @@ def test_33_get_job(self):
712712
"nodelist",
713713
"exception",
714714
]:
715-
self.assertIn(key, meta)
715+
self.assertIn(key, info)
716716

717-
self.assertEqual(meta["id"], jobid)
718-
self.assertEqual(meta["name"], "sleep")
719-
self.assertTrue(meta["state"] in ["SCHED", "DEPEND", "RUN"])
720-
self.assertEqual(meta["ntasks"], 1)
721-
self.assertEqual(meta["ncores"], 1)
717+
self.assertEqual(info["id"], jobid)
718+
self.assertEqual(info["name"], "sleep")
719+
self.assertTrue(info["state"] in ["SCHED", "DEPEND", "RUN"])
720+
self.assertEqual(info["ntasks"], 1)
721+
self.assertEqual(info["ncores"], 1)
722722

723723
# Test a job that does not exist
724-
meta = job.get_job(self.fh, 123456)
725-
self.assertIsNone(meta)
724+
info = job.get_job(self.fh, 123456)
725+
self.assertIsNone(info)
726726

727727
def test_34_timeleft(self):
728728
spec = JobspecV1.from_command(

0 commit comments

Comments
 (0)