Change in vdsm[master]: tests: add netinfo test for speed() function

Ryan Harper ryanh at us.ibm.com
Thu May 17 15:56:52 UTC 2012


Ryan Harper has posted comments on this change.

Change subject: tests: add netinfo test for speed() function
......................................................................


Patch Set 3: (1 inline comment)

....................................................
File tests/netinfoTests.py
Line 51:             self.assertTrue(s in ETHTOOL_SPEEDS or s == 0)
I don't think we can do this change... the valid speed ranges from the speed function are:

0, 10, 100, 1000, 2500, 10000

0 for the case where we cannot read the device (or we're not supposed to)

When I split it out into two asserts, we fail one or the other check.

For example:

Traceback (most recent call last):
  File "/root/work/git/clean/vdsm/tests/netinfoTests.py", line 51, in testSpeedInRange
    self.assertTrue(s in ETHTOOL_SPEEDS) or self.assertEqual(s, 0)
AssertionError: 1000 != 0

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

Gerrit-MessageType: comment
Gerrit-Change-Id: I0bf6404df05f09e984aef2f9c9264c9589d2b27e
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Ryan Harper <ryanh at us.ibm.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Igor Lvovsky <ilvovsky at redhat.com>
Gerrit-Reviewer: Ryan Harper <ryanh at us.ibm.com>


More information about the vdsm-patches mailing list