Antoni Segura Puimedon has posted comments on this change.

Change subject: tests: Add assertNotRaises assertion
......................................................................


Patch Set 1: Code-Review-1

(3 comments)

http://gerrit.ovirt.org/#/c/28177/1/tests/testrunner.py
File tests/testrunner.py:

Line 1: #
Line 2: # Copyright 2012 Red Hat, Inc.
Since I asked for a change, do you mind updating the copyright?
Line 3: #
Line 4: # This program is free software; you can redistribute it and/or modify
Line 5: # it under the terms of the GNU General Public License as published by
Line 6: # the Free Software Foundation; either version 2 of the License, or


Line 333: def not_raises(unexpected, test_case):
Line 334:     try:
Line 335:         yield
Line 336:     except unexpected as e:
Line 337:         raise test_case.failureException("Excption raised: %s" % e)
typo s/xcp/xcep/
Line 338:     except:
Line 339:         pass
Line 340: 
Line 341: 


Line 335:         yield
Line 336:     except unexpected as e:
Line 337:         raise test_case.failureException("Excption raised: %s" % e)
Line 338:     except:
Line 339:         pass
Here it should raise. Otherwise when raising other things that the one that 
shouldn't be raised you are swallowing test errors.
Line 340: 
Line 341: 
Line 342: # FIXME: This is a forward port of the assertIn from python
Line 343: #        2.7, remove when no loger supporting earlier versions


-- 
To view, visit http://gerrit.ovirt.org/28177
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I33c96ca855753a75ffe2f82bdecab2e1612da08a
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsof...@redhat.com>
Gerrit-Reviewer: Adam Litke <ali...@redhat.com>
Gerrit-Reviewer: Allon Mureinik <amure...@redhat.com>
Gerrit-Reviewer: Antoni Segura Puimedon <asegu...@redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <dan...@redhat.com>
Gerrit-Reviewer: Nir Soffer <nsof...@redhat.com>
Gerrit-Reviewer: Xavi Francisco <xfran...@redhat.com>
Gerrit-Reviewer: Yoav Kleinberger <yklei...@redhat.com>
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to