@@ -3,7 +3,8 @@ var path = require('path');
3
3
var MemoryFileSystem = require ( 'memory-fs' ) ;
4
4
var webpack = require ( 'webpack' ) ;
5
5
var _ = require ( 'lodash' ) ;
6
- var ExtractTextPlugin = require ( 'extract-text-webpack-plugin' ) ;
6
+ const MiniCssExtractPlugin = require ( 'mini-css-extract-plugin' ) ;
7
+
7
8
var FakeCopyWebpackPlugin = require ( './helpers/copy-plugin-mock' ) ;
8
9
var plugin = require ( '../index.js' ) ;
9
10
@@ -424,7 +425,7 @@ describe('ManifestPlugin', function() {
424
425
} ) ;
425
426
} ) ;
426
427
427
- describe ( 'with ExtractTextPlugin ' , function ( ) {
428
+ describe ( 'with MiniCssExtractPlugin ' , function ( ) {
428
429
it ( 'works when extracting css into a seperate file' , function ( done ) {
429
430
webpackCompile ( {
430
431
context : __dirname ,
@@ -440,17 +441,17 @@ describe('ManifestPlugin', function() {
440
441
module : {
441
442
rules : [ {
442
443
test : / \. c s s $ / ,
443
- use : ExtractTextPlugin . extract ( {
444
- fallback : 'style- loader' ,
445
- use : 'css-loader'
446
- } )
444
+ use : [
445
+ MiniCssExtractPlugin . loader ,
446
+ 'css-loader'
447
+ ]
447
448
} ]
448
449
} ,
449
450
plugins : [
450
451
new plugin ( ) ,
451
- new ExtractTextPlugin ( {
452
+ new MiniCssExtractPlugin ( {
452
453
filename : '[name].css' ,
453
- allChunks : true
454
+ // allChunks: true
454
455
} )
455
456
]
456
457
} , { } , function ( manifest , stats ) {
0 commit comments