mirror of
				https://github.com/xcat2/xcat-core.git
				synced 2025-10-30 02:42:41 +00:00 
			
		
		
		
	Add unit test cases for rspconfig
This commit is contained in:
		
							
								
								
									
										62
									
								
								xCAT-test/autotest/testcase/UT_openbmc/rspconfig_cases0
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										62
									
								
								xCAT-test/autotest/testcase/UT_openbmc/rspconfig_cases0
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,62 @@ | ||||
| start:rspconfig_record_firmware_level | ||||
| description: Record the firmware level for the start of each testcase | ||||
| hcp:openbmc | ||||
| cmd: rinv $$CN firm | ||||
| check:rc==0 | ||||
| end | ||||
|  | ||||
| start:rspconfig_get_all | ||||
| description: Check that we can get all the attributes from the BMC  | ||||
| os:Linux | ||||
| hcp:openbmc | ||||
| cmd:rspconfig $$CN ip netmask gateway hostname vlan | ||||
| check:rc==0 | ||||
| check:output=~$$CN: BMC IP: | ||||
| check:output=~$$CN: BMC Netmask: | ||||
| check:output=~$$CN: BMC Gateway: | ||||
| check:output=~$$CN: BMC Hostname: | ||||
| check:output=~$$CN: BMC VLAN ID: | ||||
| end | ||||
|  | ||||
| start:rspconfig_get_all_error | ||||
| description: Check the parsing code for rspconfig (error cases)  | ||||
| hcp: openbmc | ||||
| cmd: rspconfig $$CN ip,netmask,gateway,hostname,vlan | ||||
| check:rc==1 | ||||
| check:output=~Error: Unsupported command | ||||
| end  | ||||
|  | ||||
| start:rspconfig_get_set_error | ||||
| description: Check the parsing code for rspconfig (error cases) - Cannot get/set in same line | ||||
| hcp: openbmc | ||||
| cmd: rspconfig $$CN ip netmask=255.0.0.0 | ||||
| check:rc==1 | ||||
| check:output=~Error: Can not set and query OpenBMC information at the same time | ||||
| end | ||||
|  | ||||
| start:rspconfig_set_hostname  | ||||
| description: Check that we can set the hostname on the BMC  | ||||
| os:Linux | ||||
| hcp:openbmc | ||||
| cmd:rspconfig $$CN hostname=$$CN-UTset  | ||||
| check:rc==0 | ||||
| check:output=~$$CN: BMC Hostname: $$CN-UTset | ||||
| end  | ||||
|  | ||||
| start:rspconfig_set_hostname_check | ||||
| description: Check that the value is correct on the BMC | ||||
| os:Linux | ||||
| hcp:openbmc | ||||
| cmd:rspconfig $$CN hostname | ||||
| check:rc==0 | ||||
| check:output=~$$CN: BMC Hostname: $$CN-UTset | ||||
| end | ||||
|  | ||||
| start:rspconfig_set_hostname | ||||
| description: Check that we can set the hostname on the BMC | ||||
| os:Linux | ||||
| hcp:openbmc | ||||
| cmd:rspconfig $$CN hostname=witherspoon | ||||
| check:rc==0 | ||||
| check:output=~$$CN: BMC Hostname: witherspoon  | ||||
| end | ||||
		Reference in New Issue
	
	Block a user