functional test for SecureBoot
@@ -250,5 +250,17 @@ class redfish10_api_systems(fit_common.unittest.TestCase):
if fit_common.VERBOSITY >= 3:
print ("\t {0}".format(seldata['json']['Links']['OriginOfCondition']))
+ def test_redfish_v1_systems_id_secureboot(self):
+ # Currently relies on Dell/Racadm, so just test for exceptions
+ for nodeid in NODECATALOG:
+ api_data = fit_common.rackhdapi('/redfish/v1/Systems/' + nodeid + '/SecureBoot')
+ self.assertEqual(api_data['status'], 500, 'Incorrect HTTP return code, expected 500, got:' + str(api_data['status']))
+ api_data = fit_common.rackhdapi('/redfish/v1/Systems/' + nodeid + '/SecureBoot', action='post',
+ payload={"zzzSecureBootEnable": True})
+ self.assertEqual(api_data['status'], 400, 'Incorrect HTTP return code, expected 400, got:' + str(api_data['status']))
+ api_data = fit_common.rackhdapi('/redfish/v1/Systems/' + nodeid + '/SecureBoot', action='post',
+ payload={"SecureBootEnable": True})
+ self.assertEqual(api_data['status'], 500, 'Incorrect HTTP return code, expected 500, got:' + str(api_data['status']))
+
if __name__ == '__main__':
fit_common.unittest.main()
