Skip to content

Commit

Permalink
ci: fix css rules test
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Sep 11, 2018
1 parent a2d1095 commit 7d1818d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions packages/@vue/cli-service/__tests__/css.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,10 @@ test('css.extract', () => {
// does not support mixing config files with loader options.
expect(findLoaders(config2, lang)).toEqual(['vue-style', 'css', 'postcss', 'postcss'].concat(loader))
expect(findOptions(config2, lang, 'css').importLoaders).toBe(3)
// minification loader should be injected before the user-facing postcss-loader
expect(findOptions(config2, lang, 'postcss').plugins).toBeTruthy()
// minification loader should be injected after the user-facing postcss-loader
const rule = findRule(config2, lang)
const postcssUse = rule.use.slice().reverse().find(({ loader }) => loader === 'postcss-loader')
expect(postcssUse.options.plugins).toBeTruthy()
})
})

Expand Down
2 changes: 1 addition & 1 deletion packages/@vue/cli-service/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
"thread-loader": "^1.1.5",
"uglifyjs-webpack-plugin": "^1.2.7",
"url-loader": "^1.1.0",
"vue-loader": "^15.3.0",
"vue-loader": "^15.4.2",
"webpack": "^4.15.1",
"webpack-bundle-analyzer": "^2.13.1",
"webpack-chain": "^4.8.0",
Expand Down

0 comments on commit 7d1818d

Please sign in to comment.