You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ey...@apache.org on 2011/10/19 02:35:13 UTC
svn commit: r1185932 -
/incubator/ambari/trunk/agent/src/test/python/TestHardware.py
Author: eyang
Date: Wed Oct 19 00:35:13 2011
New Revision: 1185932
URL: http://svn.apache.org/viewvc?rev=1185932&view=rev
Log:
AMBARI-83. Fix unit test syntax to be compatible with python 2.6. (Eric Yang)
Modified:
incubator/ambari/trunk/agent/src/test/python/TestHardware.py
Modified: incubator/ambari/trunk/agent/src/test/python/TestHardware.py
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/agent/src/test/python/TestHardware.py?rev=1185932&r1=1185931&r2=1185932&view=diff
==============================================================================
--- incubator/ambari/trunk/agent/src/test/python/TestHardware.py (original)
+++ incubator/ambari/trunk/agent/src/test/python/TestHardware.py Wed Oct 19 00:35:13 2011
@@ -25,6 +25,6 @@ class TestHardware(TestCase):
def test_build(self):
hardware = Hardware()
result = hardware.get()
- self.assertGreater(result['coreCount'], 1, 'CPU can not be less than 1.')
- self.assertGreater(result['netSpeed'], 1, 'Network speed can not be less than 1.')
+ self.assertTrue(result['coreCount'] >= 1)
+ self.assertTrue(result['netSpeed'] >= 1)