tailwindcss/tests/negated-content.test.js
Brad Cornes 0b23d2e1d2
Fix using negated content globs (#5625)
* Fix negated content patterns

* Update changelog
2021-09-29 11:15:31 +01:00

27 lines
622 B
JavaScript

import * as path from 'path'
import { run, css } from './util/run'
it('should be possible to use negated content patterns', () => {
let config = {
content: [
path.resolve(__dirname, './negated-content-*.test.html'),
'!' + path.resolve(__dirname, './negated-content-ignore.test.html'),
],
corePlugins: { preflight: false },
}
let input = css`
@tailwind base;
@tailwind components;
@tailwind utilities;
`
return run(input, config).then((result) => {
expect(result.css).toMatchFormattedCss(css`
.uppercase {
text-transform: uppercase;
}
`)
})
})