Axios catch error Request failed with status code 404
问题 I'm testing a login component that uses Axios. I tried mocking Axios with axios-mock-adapter , but when I run the tests, it still errors out with: Error: Request failed with status code 404 How do I properly mock Axios in my tests? login.spec.js: import Vue from 'vue' import { shallowMount, createLocalVue } from '@vue/test-utils'; import Login from '../../src/components/global/login/Login.vue'; import Raven from "raven-js"; import jQuery from 'jquery' import Vuex from 'vuex' import router