Nir Soffer has posted comments on this change.

Change subject: jobs: Add Job.__repr__ for easier debugging
......................................................................


Patch Set 4:

(1 comment)

https://gerrit.ovirt.org/#/c/51217/4/tests/jobsTests.py
File tests/jobsTests.py:

Line 216: 
Line 217:     def test_job_repr(self):
Line 218:         job = TestingJob()
Line 219:         rep = repr(job)
Line 220:         self.assertIn("TestingJob", rep)
> not sure it is a good idea. We are committing to this format, or at least t
This is why I did not test the actual format, the test code would duplicate the 
actual code. We can decide not to test __repr__, but prefer to have 100% code 
coverage and some stupid tests compared with missing tests and runtime failures.
Line 221:         self.assertIn("id=%s" % job.id, rep)
Line 222:         self.assertIn("status=pending", rep)
Line 223:         self.assertNotIn("progress=", rep)
Line 224: 


-- 
To view, visit https://gerrit.ovirt.org/51217
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I8317fde241d064ae230093610f9aaac750fcf08f
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsof...@redhat.com>
Gerrit-Reviewer: Adam Litke <ali...@redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <dan...@redhat.com>
Gerrit-Reviewer: Francesco Romani <from...@redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsof...@redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczew...@gmail.com>
Gerrit-Reviewer: Shahar Havivi <shav...@redhat.com>
Gerrit-Reviewer: gerrit-hooks <automat...@ovirt.org>
Gerrit-HasComments: Yes
_______________________________________________
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to