[OpenBMC] Test BIOS version
Resolves openbmc/openbmc-test-automation#79
Change-Id: I96fc1b25cabf27a1f2475c556e48e13bef483f9a
Signed-off-by: Sridevi Ramesh <sridevra@in.ibm.com>
diff --git a/tests/test_fw_version.robot b/tests/test_fw_version.robot
old mode 100644
new mode 100755
index 90721b7..cf384b4
--- a/tests/test_fw_version.robot
+++ b/tests/test_fw_version.robot
@@ -1,16 +1,15 @@
*** Settings ***
-Documentation This suite will the firmware version exposed part of
-... system inventory
+Documentation This suite is for Verifying BMC & BIOS version exposed part
+... of system inventory
Resource ../lib/rest_client.robot
*** Variables ***
-
*** Test Cases ***
-Test Firmware Version
- [Documentation] This testcase is for testing the fw version.\n
+Test BMC Version
+ [Documentation] Verifying if the BMC Version field is set with valid strings.\n
... Expected in following format:
... $ git describe --dirty
... v0.1-34-g95f7347
@@ -18,5 +17,18 @@
${resp} = OpenBMC Get Request /org/openbmc/inventory/system/chassis/motherboard/bmc
Should Be Equal As Strings ${resp.status_code} ${HTTP_OK}
${jsondata}= To Json ${resp.content}
- Should not be empty ${jsondata["data"]["version"]}
- Should Match Regexp ${jsondata["data"]["version"]} ^v\\d+\.\\d+
\ No newline at end of file
+ Should not be empty ${jsondata["data"]["version"]} msg=version field is empty
+ Should Match Regexp ${jsondata["data"]["version"]} ^v\\d+\.\\d+
+
+Test BIOS Version
+ [Documentation] Verifying if the BIOS Version field is set with valid strings.\n
+ ... Expected in following format:
+ ... open-power-barreleye-v1.8
+ ... $
+
+ [Tags] chassisboot
+ ${resp} = OpenBMC Get Request /org/openbmc/inventory/system/bios
+ Should Be Equal As Strings ${resp.status_code} ${HTTP_OK}
+ ${jsondata}= To Json ${resp.content}
+ Should not be empty ${jsondata["data"]["Version"]} msg=Version field is empty
+ Should Match Regexp ${jsondata["data"]["Version"]} ^open+\-\power+\-\