diff --git a/providers/asrockrack/mock_test.go b/providers/asrockrack/mock_test.go index 3a603480..7f630ae9 100644 --- a/providers/asrockrack/mock_test.go +++ b/providers/asrockrack/mock_test.go @@ -82,6 +82,7 @@ func mockASRockBMC() *httptest.Server { // fw update endpoints - in order of invocation handler.HandleFunc("/api/maintenance/flash", bmcFirmwareUpgrade) handler.HandleFunc("/api/maintenance/firmware", bmcFirmwareUpgrade) + handler.HandleFunc("/api/maintenance/firmware/firmware", bmcFirmwareUpgrade) handler.HandleFunc("/api/maintenance/firmware/verification", bmcFirmwareUpgrade) handler.HandleFunc("/api/maintenance/firmware/upgrade", bmcFirmwareUpgrade) handler.HandleFunc("/api/maintenance/firmware/flash-progress", bmcFirmwareUpgrade) @@ -212,6 +213,9 @@ func bmcFirmwareUpgrade(w http.ResponseWriter, r *http.Request) { // 2. upload firmware case "/api/maintenance/firmware": + // make it fail to test the other URL + w.WriteHeader(http.StatusBadRequest) + case "/api/maintenance/firmware/firmware": // validate flash mode set if !fwUpgradeState.FlashModeSet {