ctimmerm/axios-mock-adapter

axios instance is not mocked

syffs opened this issue · 1 comments

syffs commented

Versions:

  • NodeJS: 16.13.0
  • axios: 0.26.1
  • axios-mock-adapter: 1.20.0
  • Typescript: 4.6.3
  • system: WSL Ubuntu 18.04

As in title, here is a repro with axios test. Just clone, then yarn install && yarn build && yarn test.
Using onNoMatch: "throwException" has no effect.

is there a way to somehow mock axios globally (for every instance) ?