mirror of
https://github.com/primer/css.git
synced 2024-09-11 16:36:07 +03:00
34 lines
891 B
JavaScript
34 lines
891 B
JavaScript
import {
|
|
getCurrentVersion,
|
|
getPackageStats,
|
|
getSelectorDiff,
|
|
getVariableDiff,
|
|
currentVersionDeprecations
|
|
} from './utils/css'
|
|
import semver from 'semver'
|
|
|
|
let selectorsDiff, variablesDiff, version
|
|
|
|
beforeAll(async () => {
|
|
selectorsDiff = getSelectorDiff()
|
|
variablesDiff = getVariableDiff()
|
|
version = getCurrentVersion()
|
|
})
|
|
|
|
describe('css', () => {
|
|
it('The support.css file contains no compiled css', () => {
|
|
const supportStats = getPackageStats('support')
|
|
expect(supportStats.size).toEqual(0)
|
|
})
|
|
})
|
|
|
|
describe('deprecations', () => {
|
|
it('expects deprecations and their replacement to not be equal.', () => {
|
|
const deprecations = currentVersionDeprecations()
|
|
Object.keys(deprecations["selectors"]).forEach(deprecation => {
|
|
const replacement = deprecations["selectors"][deprecation]
|
|
expect(deprecation).not.toEqual(replacement)
|
|
})
|
|
})
|
|
})
|