Skip to content

Commit

Permalink
chore(test): update tests for "css" handler
Browse files Browse the repository at this point in the history
  • Loading branch information
Kocal committed May 7, 2019
1 parent e376820 commit 2d8681f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
9 changes: 9 additions & 0 deletions test/fixtures/css/package.json
Expand Up @@ -17,6 +17,15 @@
"src": "src/style.css",
"dest": "dist/",
"concat": "style.css"
},
{
"handler": "css",
"src": [
"node_modules/bootstrap/dist/css/bootstrap-reboot.css",
"node_modules/bootstrap/dist/css/bootstrap-grid.css"
],
"dest": "dist/",
"concat": "bootstrap-reboot-and-grid.css"
}
]
}
Expand Down
3 changes: 3 additions & 0 deletions test/functional/api/commands/build.test.ts
Expand Up @@ -234,11 +234,14 @@ describe('command: build', () => {
expect(api.logger.info).toHaveBeenCalledWith('sass :: finished bundling "bootstrap-grid.css"');
expect(api.logger.info).toHaveBeenCalledWith('css :: start bundling "style.css"');
expect(api.logger.info).toHaveBeenCalledWith('css :: finished bundling "style.css"');
expect(api.logger.info).toHaveBeenCalledWith('css :: start bundling "bootstrap-reboot-and-grid.css"');
expect(api.logger.info).toHaveBeenCalledWith('css :: finished bundling "bootstrap-reboot-and-grid.css"');

expect(await readFile('src/bootstrap-grid.scss')).toMatchSnapshot('bootstrap-grid.scss after linting');
expect(await readFile('src/style.css')).toMatchSnapshot('style.css after linting');
expect(await fileExists('dist/bootstrap-grid.css')).toBeTruthy();
expect(await fileExists('dist/style.css')).toBeTruthy();
expect(await fileExists('dist/bootstrap-reboot-and-grid.css')).toBeTruthy();

await cleanup();
}, 30000);
Expand Down

0 comments on commit 2d8681f

Please sign in to comment.