Warning frontend test about ListWorkerConfigurations
There is an undesired warning in the tests.
Process/Workers/Configurations/List.vue
[Vue warn]: Error in v-on handler (Promise/async): "Error: Request failed with status code 400"
found in
---> <List> at vue/Process/Workers/Configurations/List.vue
<Root>
Error: Request failed with status code 400
at createAxiosError (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios-mock-adapter/src/utils.js:147:15)
at Object.settle (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios-mock-adapter/src/utils.js:126:9)
at handleRequest (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios-mock-adapter/src/handle_request.js:67:13)
at /home/yschneider/Work/Teklia/ark-frontend/node_modules/axios-mock-adapter/src/index.js:26:9
at new Promise (<anonymous>)
at MockAdapter.<anonymous> (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios-mock-adapter/src/index.js:25:14)
at /home/yschneider/Work/Teklia/ark-frontend/test/testhelpers.js:95:1
at dispatchRequest (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios/lib/core/dispatchRequest.js:53:10)
at Axios.request (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios/lib/core/Axios.js:108:15)
at Axios.<computed> [as patch] (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios/lib/core/Axios.js:140:17)
at Function.wrap [as patch] (/home/yschneider/Work/Teklia/ark-frontend/node_modules/axios/lib/helpers/bind.js:9:15)
at Module.updateWorkerRun (/home/yschneider/Work/Teklia/ark-frontend/js/api.js:260:1)
at updateWorkerRun (/home/yschneider/Work/Teklia/ark-frontend/js/store/process.js:286:1)
at Object.actions.<computed> [as process/updateWorkerRun] (/home/yschneider/Work/Teklia/ark-frontend/test/testhelpers.js:263:1)
at FakeStore.dispatch (/home/yschneider/Work/Teklia/ark-frontend/test/testhelpers.js:325:1)
at VueComponent.saveConfiguration (/home/yschneider/Work/Teklia/ark-frontend/.tmp/mochapack/1639560344330/vue/Process/Workers/Configurations/List.vue:155:1) {
isAxiosError: true,
config: {
url: '/imports/workers/workerRun1/',
method: 'patch',
data: '{"configuration_id":"configid1"}',
headers: {
Accept: 'application/json, text/plain, */*',
'Content-Type': 'application/json'
},
transformRequest: [ [Function: transformRequest] ],
transformResponse: [ [Function: transformResponse] ],
timeout: 0,
xsrfCookieName: 'XSRF-TOKEN',
xsrfHeaderName: 'X-XSRF-TOKEN',
maxContentLength: -1,
maxBodyLength: -1,
validateStatus: [Function: validateStatus],
transitional: {
silentJSONParsing: true,
forcedJSONParsing: true,
clarifyTimeoutError: false
}
},
response: {
status: 400,
data: { detail: 'Something went wrong.' },
headers: undefined,
config: {
url: '/imports/workers/workerRun1/',
method: 'patch',
data: '{"configuration_id":"configid1"}',
headers: [Object],
transformRequest: [Array],
transformResponse: [Array],
timeout: 0,
xsrfCookieName: 'XSRF-TOKEN',
xsrfHeaderName: 'X-XSRF-TOKEN',
maxContentLength: -1,
maxBodyLength: -1,
validateStatus: [Function: validateStatus],
transitional: [Object]
},
request: { responseUrl: '/imports/workers/workerRun1/' }
}
}