I'm new to Vue and am learning how to test it from this tutorial. I've reached the end of the tutorial but am getting a strange error on the last step of using avoriaz
:
ERROR in ./test/unit/specs/list.spec.js
Module not found: Error: Can't resolve 'avoriaz' in
'/local/path/to/vuejs-
testing/test/unit/specs'
@ ./test/unit/specs/list.spec.js 3:15-33
@ ./test/unit/specs \.spec$
@ ./test/unit/index.js
Here's the relevant code in my test file:
import { mount } from 'avoriaz';
import List from '@/components/List';
import Vue from 'vue';
...
And my package.json
file:
...
},
"dependencies": {
"vue": "^2.3.3",
"vue-router": "^2.6.0"
},
"devDependencies": {
"autoprefixer": "^7.1.2",
"avoriaz": "^2.6.3",
...
I tried removing my node_modules
directory and package-lock.json
and reinstalling everything with npm install
to no avail.
Any ideas as to what could be causing this, and how to resolve it?
author of avoriaz here. This was a bug with avoriaz 2.6.3, it's fixed in 2.6.5.
The problem was I switched the way the file was exported. This caused problems for most users.