Commit aa4598bf by Johannes Edmeier

fix jest setup

parent f73da8ec
......@@ -30,8 +30,8 @@
"moment": "^2.21.0",
"moment-shortformat": "^2.1.0",
"pretty-bytes": "^4.0.2",
"rxjs": "^5.5.6",
"vue": "^2.5.15",
"rxjs": "^5.5.7",
"vue": "^2.5.16",
"vue-clickaway": "^2.1.0",
"vue-router": "^3.0.1",
"yamljs": "^0.3.0"
......@@ -63,17 +63,17 @@
"html-webpack-plugin": "^2.30.0",
"identity-obj-proxy": "^3.0.0",
"jest": "^22.4.2",
"jest-vue": "^0.8.2",
"lodash-webpack-plugin": "^0.11.4",
"node-sass": "^4.7.2",
"node-sass": "^4.8.2",
"optimize-css-assets-webpack-plugin": "^3.2.0",
"postcss-loader": "^2.1.1",
"sass-loader": "^6.0.7",
"style-loader": "^0.20.3",
"url-loader": "^0.6.2",
"vue-jest": "^2.1.1",
"vue-loader": "^14.2.1",
"vue-svg-loader": "^0.5.0",
"vue-template-compiler": "^2.5.15",
"vue-template-compiler": "^2.5.16",
"webpack": "^3.11.0",
"webpack-bundle-analyzer": "^2.11.1"
},
......@@ -89,12 +89,11 @@
"vue"
],
"moduleNameMapper": {
"\\.(jpg|jpeg|png|gif|eot|otf|webp|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/src/test/frontend/__mocks__/file-mock.js",
"\\.(css|scss)$": "<rootDir>/__mocks__/file-mocks.js"
"\\.(jpg|jpeg|png|gif|eot|otf|webp|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/src/test/frontend/__mocks__/file-mock.js"
},
"transform": {
"\\.js$": "babel-jest",
"\\.vue$": "jest-vue",
"\\.vue$": "vue-jest",
"\\.svg$": "<rootDir>/src/test/frontend/__mocks__/vue-mock-component.js"
},
"transformIgnorePatterns": [
......
......@@ -4,9 +4,7 @@ exports[`application-status should match the snapshot with custom status 1`] = `
<div
class="application-status"
>
<font-awesome-icon
class="application-status__icon application-status__icon--?"
/>
<!---->
<!---->
</div>
......@@ -16,10 +14,7 @@ exports[`application-status should match the snapshot with status DOWN 1`] = `
<div
class="application-status"
>
<font-awesome-icon
class="application-status__icon application-status__icon--DOWN"
icon="times-circle"
/>
<!---->
<!---->
</div>
......@@ -29,10 +24,7 @@ exports[`application-status should match the snapshot with status OFFLINE 1`] =
<div
class="application-status"
>
<font-awesome-icon
class="application-status__icon application-status__icon--OFFLINE"
icon="minus-circle"
/>
<!---->
<!---->
</div>
......@@ -42,10 +34,7 @@ exports[`application-status should match the snapshot with status OUT_OF_SERVICE
<div
class="application-status"
>
<font-awesome-icon
class="application-status__icon application-status__icon--OUT_OF_SERVICE"
icon="ban"
/>
<!---->
<!---->
</div>
......@@ -55,10 +44,7 @@ exports[`application-status should match the snapshot with status RESTRICTED 1`]
<div
class="application-status"
>
<font-awesome-icon
class="application-status__icon application-status__icon--RESTRICTED"
icon="exclamation"
/>
<!---->
<!---->
</div>
......@@ -68,10 +54,7 @@ exports[`application-status should match the snapshot with status UNKNOWN 1`] =
<div
class="application-status"
>
<font-awesome-icon
class="application-status__icon application-status__icon--UNKNOWN"
icon="question-circle"
/>
<!---->
<!---->
</div>
......@@ -81,10 +64,7 @@ exports[`application-status should match the snapshot with status UP with Timest
<div
class="application-status"
>
<font-awesome-icon
class="application-status__icon application-status__icon--UP"
icon="check"
/>
<!---->
<small>
14m
......
......@@ -27,6 +27,9 @@ describe('application-status', () => {
propsData: {
status,
date
},
stubs: {
'font-awesome-icon': true
}
});
expect(wrapper.vm.$el).toMatchSnapshot();
......@@ -60,4 +63,4 @@ describe('application-status', () => {
testSnapshotForStatus('?');
});
});
\ No newline at end of file
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment