blob: 53de6199a913a3bd3e59e0d528206fc8c186706c [file] [log] [blame]
Chris Austenb29d2e82016-06-07 12:25:35 -05001*** Settings ***
Sridevi Ramesh206173d2016-08-16 05:41:40 -05002Documentation This suite is for Verifying BMC & BIOS version exposed part
3... of system inventory
Chris Austenb29d2e82016-06-07 12:25:35 -05004
5Resource ../lib/rest_client.robot
George Keishingd55a4be2016-08-26 03:28:17 -05006Resource ../lib/openbmc_ffdc.robot
Gunnar Millseac1af22016-11-14 15:30:09 -06007Test Teardown FFDC On Test Case Fail
Chris Austenb29d2e82016-06-07 12:25:35 -05008
9
10*** Variables ***
11
Chris Austenb29d2e82016-06-07 12:25:35 -050012*** Test Cases ***
Sridevi Ramesh206173d2016-08-16 05:41:40 -050013Test BMC Version
14 [Documentation] Verifying if the BMC Version field is set with valid strings.\n
Chris Austenb29d2e82016-06-07 12:25:35 -050015 ... Expected in following format:
16 ... $ git describe --dirty
17 ... v0.1-34-g95f7347
18 ... $
Sridevi Ramesh83f5c592017-01-20 04:35:13 -060019 [Tags] Test_BMC_Version
20
George Keishingec807372016-12-05 03:54:51 -060021 ${resp}= OpenBMC Get Request
22 ... ${INVENTORY_URI}system/chassis/motherboard/bmc
Chris Austenb29d2e82016-06-07 12:25:35 -050023 Should Be Equal As Strings ${resp.status_code} ${HTTP_OK}
24 ${jsondata}= To Json ${resp.content}
Sridevi Ramesh206173d2016-08-16 05:41:40 -050025 Should not be empty ${jsondata["data"]["version"]} msg=version field is empty
26 Should Match Regexp ${jsondata["data"]["version"]} ^v\\d+\.\\d+
27
28Test BIOS Version
29 [Documentation] Verifying if the BIOS Version field is set with valid strings.\n
30 ... Expected in following format:
31 ... open-power-barreleye-v1.8
32 ... $
Rahul Maheshwaribb20f732016-10-24 06:27:14 -050033 [Tags] chassisboot Test_BIOS_Version
Sridevi Ramesh83f5c592017-01-20 04:35:13 -060034
George Keishingec807372016-12-05 03:54:51 -060035 ${resp}= OpenBMC Get Request ${INVENTORY_URI}system/bios
Sridevi Ramesh206173d2016-08-16 05:41:40 -050036 Should Be Equal As Strings ${resp.status_code} ${HTTP_OK}
37 ${jsondata}= To Json ${resp.content}
38 Should not be empty ${jsondata["data"]["Version"]} msg=Version field is empty
39 Should Match Regexp ${jsondata["data"]["Version"]} ^open+\-\power+\-\