Fix variable as integer for power cap
The integer variable populating as dictionary data have a string char
{u'data': u'0'}
due to scalar conversion from set variable to dictionary data for POST
operation.
With the change
{u'data': 0}
the data remains as integer thus accepting this POST request to write
to power_cap
Resolves openbmc/openbmc-test-automation#141
Change-Id: I7d99023bc07b24781dcffd53d19e75007993f210
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/tests/test_generic_conf.robot b/tests/test_generic_conf.robot
index bdd6c97..f2a4913 100755
--- a/tests/test_generic_conf.robot
+++ b/tests/test_generic_conf.robot
@@ -9,8 +9,8 @@
*** Variables ***
-${MIN_POWER_VALUE} 0
-${MAX_POWER_VALUE} 1000
+${MIN_POWER_VALUE} ${0}
+${MAX_POWER_VALUE} ${1000}
*** Test Cases ***
@@ -19,15 +19,15 @@
[Documentation] ***GOOD PATH***
... This test case tries to get the boot flags
- ...
+ ...
${resp}= Read Attribute /org/openbmc/settings/host0/ boot_flags
should not be empty ${resp}
Get the power
-
+
[Documentation] ***GOOD PATH***
- ... This test case tries to get the power value and it should be
+ ... This test case tries to get the power value and it should be
... between ${MIN_POWER_VALUE} and ${MAX_POWER_VALUE}
${powerValue}= Read Attribute /org/openbmc/settings/host0/ power_cap