Skip to content

Commit 66c7b95

Browse files
committed
Rename css -> rawCss, objectCss -> expectedJSS in tests
1 parent 4f3b52a commit 66c7b95

3 files changed

Lines changed: 14 additions & 14 deletions

File tree

tests/default-config/index.test.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { asyncParser } from '../../src'
22

3-
const css = `
3+
const rawCSS = `
44
button {
55
color: #ffffff;
66
width: 100px;
@@ -12,7 +12,7 @@ const css = `
1212
}
1313
`
1414

15-
const objectCss = {
15+
const expectedJSS = {
1616
button: {
1717
color: '#ffffff',
1818
width: '100px',
@@ -28,7 +28,7 @@ beforeAll(() => {
2828
})
2929

3030
it('should handle default config', async () => {
31-
const result = await asyncParser(css)
31+
const result = await asyncParser(rawCSS)
3232

33-
expect(result).toEqual(objectCss)
33+
expect(result).toEqual(expectedJSS)
3434
})

tests/parser.test.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
import { syncParser, asyncParser } from '../src'
22

3-
const css = `
3+
const rawCSS = `
44
button {
55
color: #ffffff;
66
width: 100px;
77
height: 70px;
88
}
99
`
1010

11-
const objectCss = {
11+
const expectedJSS = {
1212
button: {
1313
color: '#ffffff',
1414
width: '100px',
@@ -23,13 +23,13 @@ const options = {
2323
}
2424

2525
it('sync parse from plain css to object', () => {
26-
const result = syncParser(css, options)
26+
const result = syncParser(rawCSS, options)
2727

28-
expect(result).toEqual(objectCss)
28+
expect(result).toEqual(expectedJSS)
2929
})
3030

3131
it('async parse from plain css to object', async () => {
32-
const result = await asyncParser(css, options)
32+
const result = await asyncParser(rawCSS, options)
3333

34-
expect(result).toEqual(objectCss)
34+
expect(result).toEqual(expectedJSS)
3535
})

tests/postcssrc/index.test.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { asyncParser } from '../../src'
22

3-
const css = `
3+
const rawCSS = `
44
button {
55
color: #ffffff;
66
width: 100px;
@@ -12,7 +12,7 @@ const css = `
1212
}
1313
`
1414

15-
const objectCss = {
15+
const expectedJSS = {
1616
button: {
1717
color: '#ffffff',
1818
width: '100px',
@@ -28,7 +28,7 @@ beforeAll(() => {
2828
})
2929

3030
it('should handle postcssrc config', async () => {
31-
const result = await asyncParser(css)
31+
const result = await asyncParser(rawCSS)
3232

33-
expect(result).toEqual(objectCss)
33+
expect(result).toEqual(expectedJSS)
3434
})

0 commit comments

Comments
 (0)