File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -8,19 +8,30 @@ test('sheetify-sass', function (t) {
88 t . test ( 'should transform sass and scss' , function ( t ) {
99 const expected = fs . readFileSync ( path . join ( __dirname , 'expected.css' ) )
1010
11- t . plan ( 2 )
11+ t . plan ( 4 )
12+
13+ const files = new Set ( )
1214 browserify ( path . join ( __dirname , 'source.js' ) )
15+ . on ( 'transform' , function ( transform ) {
16+ transform . on ( 'file' , function ( filename ) {
17+ files . add ( filename )
18+ } )
19+ } )
1320 . transform ( 'sheetify' , {
1421 transform : [ './' ]
1522 } )
1623 . plugin ( 'css-extract' , {
1724 out : createWs
18- } ) . bundle ( )
25+ } )
26+ . bundle ( )
1927
2028 function createWs ( ) {
2129 return bl ( function ( err , buf ) {
2230 t . ifError ( err , 'no error' )
2331 t . equal ( String ( buf ) . trim ( ) , String ( expected ) . trim ( ) )
32+
33+ t . ok ( files . has ( path . join ( __dirname , 'import.scss' ) ) )
34+ t . ok ( files . has ( path . join ( __dirname , 'indent-import.sass' ) ) )
2435 } )
2536 }
2637 } )
You can’t perform that action at this time.
0 commit comments