Skip to content

Commit

Permalink
test(spec): check that PostCSS doesn't warn about misplaced @charset
Browse files Browse the repository at this point in the history
  • Loading branch information
Emanuel Kluge authored and ZauberNerd committed Feb 1, 2021
1 parent c31efbd commit 3f420ca
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
18 changes: 18 additions & 0 deletions packages/spec/integration/postcss/__tests__/build.js
@@ -0,0 +1,18 @@
/**
* @jest-hops-puppeteer off
*/

describe('postcss - build', () => {
let stderr;

beforeAll(async () => {
const result = await HopsCLI.build('-p', '--parallel-build');
stderr = result.stderr;
});

it('should not output a @charset warning', () => {
expect(stderr).not.toContain(
'postcss-import: @charset must precede all other statements'
);
});
});
1 change: 1 addition & 0 deletions packages/spec/integration/postcss/styles.css
@@ -1,5 +1,6 @@
@import url(imported-from-css.css);
@import '@vishnucss/chips';
@charset 'utf-8';

.headline {
composes: compose from './for-composing.css';
Expand Down

0 comments on commit 3f420ca

Please sign in to comment.