Skip to content

Commit

Permalink
use toMatchSnapshot instead of toMatchFormattedCss
Browse files Browse the repository at this point in the history
More info: #12170
  • Loading branch information
RobinMalfait committed Oct 9, 2023
1 parent b30761a commit 56ae7e6
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 18 deletions.
25 changes: 25 additions & 0 deletions tests/plugins/__snapshots__/colorScheme.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`should test the 'colorScheme' plugin 1`] = `
"
.color-scheme-dark {
color-scheme: dark;
}
.color-scheme-light {
color-scheme: light;
}
.color-scheme-light-dark {
color-scheme: light dark;
}
.color-scheme-dark-only {
color-scheme: dark only;
}
.color-scheme-light-only {
color-scheme: light only;
}
"
`;
20 changes: 2 additions & 18 deletions tests/plugins/colorScheme.test.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,3 @@
import { css, quickPluginTest } from '../util/run'
import { quickPluginTest } from '../util/run'

quickPluginTest('colorScheme').toMatchFormattedCss(css`
.color-scheme-dark {
color-scheme: dark;
}
.color-scheme-light {
color-scheme: light;
}
.color-scheme-light-dark {
color-scheme: light dark;
}
.color-scheme-dark-only {
color-scheme: dark only;
}
.color-scheme-light-only {
color-scheme: light only;
}
`)
quickPluginTest('colorScheme').toMatchSnapshot()

0 comments on commit 56ae7e6

Please sign in to comment.