tailwindcss/__tests__/cli.compile.test.js
Robin Malfait 784af4313a check for different -webkit prefix test
The tests started failing because `-webkit-max-content` is not needed
anymore. So instead we are now checking for `-webkit-background-clip`.

If this happens in the future, we could check for ` -webkit-` (notice
the space in front) so that we dont test for hardcoded
`::-webkit-inner-spin-button`.
2021-04-02 15:13:21 -04:00

20 lines
557 B
JavaScript

import path from 'path'
import autoprefixer from 'autoprefixer'
import tailwind from '../src'
import compile from '../src/cli/compile'
describe('cli compile', () => {
const inputFile = path.resolve(__dirname, 'fixtures/tailwind-input.css')
const outputFile = 'output.css'
const plugins = [tailwind(), autoprefixer]
it('compiles CSS file', () => {
return compile({ inputFile, outputFile, plugins }).then((result) => {
expect(result.css).toContain('.example')
expect(result.css).toContain('-webkit-background-clip')
})
})
})