1
1
// Jest Snapshot v1, https://goo.gl/fbAQLP
2
2
3
- exports [` Config Options should emit error when invalid config : errors 1` ] = `
3
+ exports [` "config" option should throw an error on the invalid config: errors 1` ] = `
4
4
Array [
5
5
"ModuleBuildError: Module build failed (from \` replaced original path\` ):
6
6
Error: invalid postcss config",
7
7
]
8
8
` ;
9
9
10
- exports [` Config Options should emit error when invalid config : warnings 1` ] = ` Array []` ;
10
+ exports [` "config" option should throw an error on the invalid config: warnings 1` ] = ` Array []` ;
11
11
12
- exports [` Config Options should emit error when unresolved config : errors 1` ] = `
12
+ exports [` "config" option should throw an error on the unresolved config: errors 1` ] = `
13
13
Array [
14
14
"ModuleBuildError: Module build failed (from \` replaced original path\` ):
15
15
Error: No PostCSS Config found in: /test/fixtures/config-scope/css/unresolve.js",
16
16
]
17
17
` ;
18
18
19
- exports [` Config Options should emit error when unresolved config : warnings 1` ] = ` Array []` ;
19
+ exports [` "config" option should throw an error on the unresolved config: warnings 1` ] = ` Array []` ;
20
20
21
- exports [` Config Options should work "config" and "postcssOptions" options : css 1` ] = `
21
+ exports [` "config" option should work "string" value (relative path) : css 1` ] = `
22
22
"a { color : rgba (0 , 0 , 0 , 1.0 ) }
23
23
24
- [dir=ltr] .foo { float : right ;
25
- }
26
-
27
- [dir=rtl] .foo {
28
- float : left ;
24
+ .foo {
25
+ float : right ;
29
26
}
30
27
"
31
28
` ;
32
29
33
- exports [` Config Options should work "config" and "postcssOptions" options : errors 1` ] = ` Array []` ;
30
+ exports [` "config" option should work "string" value (relative path) : errors 1` ] = ` Array []` ;
34
31
35
- exports [` Config Options should work "config" and "postcssOptions" options : warnings 1` ] = ` Array []` ;
32
+ exports [` "config" option should work "string" value (relative path) : warnings 1` ] = ` Array []` ;
36
33
37
- exports [` Config Options should work Config - "string" with path directory : css 1` ] = `
34
+ exports [` "config" option should work Config - Context - { Object } : css 1` ] = `
38
35
"a { color : rgba (0 , 0 , 0 , 1.0 ) }
39
36
40
37
.foo {
@@ -43,24 +40,28 @@ exports[`Config Options should work Config - "string" with path directory: css 1
43
40
"
44
41
` ;
45
42
46
- exports [` Config Options should work Config - "string" with path directory : errors 1` ] = ` Array []` ;
43
+ exports [` "config" option should work Config - Context - { Object } : errors 1` ] = ` Array []` ;
47
44
48
- exports [` Config Options should work Config - "string" with path directory : warnings 1` ] = ` Array []` ;
45
+ exports [` "config" option should work Config - Context - { Object } : warnings 1` ] = ` Array []` ;
49
46
50
- exports [` Config Options should work Config - "string" with relative path : css 1` ] = `
51
- "a { color : rgba ( 0 , 0 , 0 , 1.0 ) }
47
+ exports [` "config" option should work Config - Path - { String } : css 1` ] = `
48
+ "a { color : black }
52
49
53
50
.foo {
54
51
float : right ;
55
52
}
56
53
"
57
54
` ;
58
55
59
- exports [` Config Options should work Config - "string" with relative path: errors 1` ] = ` Array []` ;
56
+ exports [` "config" option should work Config - Path - { String } : errors 1` ] = ` Array []` ;
57
+
58
+ exports [` "config" option should work Config - Path - { String } : warnings 1` ] = ` Array []` ;
59
+
60
+ exports [` "config" option should work Config – Context – Loader { Object } : errors 1` ] = ` Array []` ;
60
61
61
- exports [` Config Options should work Config - "string" with relative path : warnings 1` ] = ` Array []` ;
62
+ exports [` "config" option should work Config – Context – Loader { Object } : warnings 1` ] = ` Array []` ;
62
63
63
- exports [` Config Options should work Config - "string" : css 1` ] = `
64
+ exports [` "config" option should work with "Object" value : css 1` ] = `
64
65
"a { color : rgba (0 , 0 , 0 , 1.0 ) }
65
66
66
67
.foo {
@@ -69,76 +70,82 @@ exports[`Config Options should work Config - "string": css 1`] = `
69
70
"
70
71
` ;
71
72
72
- exports [` Config Options should work Config - "string" : errors 1` ] = ` Array []` ;
73
+ exports [` "config" option should work with "Object" value : errors 1` ] = ` Array []` ;
73
74
74
- exports [` Config Options should work Config - "string" : warnings 1` ] = ` Array []` ;
75
+ exports [` "config" option should work with "Object" value : warnings 1` ] = ` Array []` ;
75
76
76
- exports [` Config Options should work Config - { Object } : css 1` ] = `
77
- "a { color : rgba ( 0 , 0 , 0 , 1.0 ) }
77
+ exports [` "config" option should work with "false" value : css 1` ] = `
78
+ "a { color : black }
78
79
79
80
.foo {
80
81
float : right ;
81
82
}
82
83
"
83
84
` ;
84
85
85
- exports [` Config Options should work Config - { Object } : errors 1` ] = ` Array []` ;
86
+ exports [` "config" option should work with "false" value : errors 1` ] = ` Array []` ;
86
87
87
- exports [` Config Options should work Config - { Object } : warnings 1` ] = ` Array []` ;
88
+ exports [` "config" option should work with "false" value : warnings 1` ] = ` Array []` ;
88
89
89
- exports [` Config Options should work Config - Context - { Object } : css 1` ] = `
90
- "a { color : rgba (0 , 0 , 0 , 1.0 ) }
90
+ exports [` "config" option should work with "package.json": css 1` ] = `
91
+ ".import {
92
+ color : red ;
93
+ }
91
94
92
- .foo {
93
- float : right ;
95
+ .test {
96
+ color : blue ;
94
97
}
95
98
"
96
99
` ;
97
100
98
- exports [` Config Options should work Config - Context - { Object } : errors 1` ] = ` Array []` ;
101
+ exports [` "config" option should work with "package.json" : errors 1` ] = ` Array []` ;
99
102
100
- exports [` Config Options should work Config - Context - { Object } : warnings 1` ] = ` Array []` ;
103
+ exports [` "config" option should work with "package.json" : warnings 1` ] = ` Array []` ;
101
104
102
- exports [` Config Options should work Config - Object - path file: css 1` ] = `
103
- "a { color : rgba (0 , 0 , 0 , 1.0 ) }
105
+ exports [` "config" option should work with "postcss.config.js" and the array syntax of the "plugin" option: css 1` ] = `
106
+ ".import {
107
+ color : red ;
108
+ }
104
109
105
- .foo {
106
- float : right ;
110
+ .test {
111
+ color : cyan ;
107
112
}
108
113
"
109
114
` ;
110
115
111
- exports [` Config Options should work Config - Object - path file : errors 1` ] = ` Array []` ;
116
+ exports [` "config" option should work with "postcss.config.js" and the array syntax of the "plugin" option : errors 1` ] = ` Array []` ;
112
117
113
- exports [` Config Options should work Config - Object - path file : warnings 1` ] = ` Array []` ;
118
+ exports [` "config" option should work with "postcss.config.js" and the array syntax of the "plugin" option : warnings 1` ] = ` Array []` ;
114
119
115
- exports [` Config Options should work Config - Path - { String } : css 1` ] = `
116
- "a { color : black }
120
+ exports [` "config" option should work with "postcss.config.js" and the object syntax of the "plugin" option: css 1` ] = `
121
+ ".import {
122
+ color : red ;
123
+ }
117
124
118
- .foo {
119
- float : right ;
125
+ .test {
126
+ color : blue ;
120
127
}
121
128
"
122
129
` ;
123
130
124
- exports [` Config Options should work Config - Path - { String } : errors 1` ] = ` Array []` ;
131
+ exports [` "config" option should work with "postcss.config.js" and the object syntax of the "plugin" option : errors 1` ] = ` Array []` ;
125
132
126
- exports [` Config Options should work Config - Path - { String } : warnings 1` ] = ` Array []` ;
133
+ exports [` "config" option should work with "postcss.config.js" and the object syntax of the "plugin" option : warnings 1` ] = ` Array []` ;
127
134
128
- exports [` Config Options should work Config - false : css 1` ] = `
129
- "a { color : black }
135
+ exports [` "config" option should work with "string" value (absolute path) : css 1` ] = `
136
+ "a { color : rgba ( 0 , 0 , 0 , 1.0 ) }
130
137
131
138
.foo {
132
139
float : right ;
133
140
}
134
141
"
135
142
` ;
136
143
137
- exports [` Config Options should work Config - false : errors 1` ] = ` Array []` ;
144
+ exports [` "config" option should work with "string" value (absolute path) : errors 1` ] = ` Array []` ;
138
145
139
- exports [` Config Options should work Config - false : warnings 1` ] = ` Array []` ;
146
+ exports [` "config" option should work with "string" value (absolute path) : warnings 1` ] = ` Array []` ;
140
147
141
- exports [` Config Options should work Config - true : css 1` ] = `
148
+ exports [` "config" option should work with "string" value (path to directory with the configuration) : css 1` ] = `
142
149
"a { color : rgba (0 , 0 , 0 , 1.0 ) }
143
150
144
151
.foo {
@@ -147,106 +154,60 @@ exports[`Config Options should work Config - true: css 1`] = `
147
154
"
148
155
` ;
149
156
150
- exports [` Config Options should work Config - true: errors 1` ] = ` Array []` ;
151
-
152
- exports [` Config Options should work Config - true: warnings 1` ] = ` Array []` ;
157
+ exports [` "config" option should work with "string" value (path to directory with the configuration): errors 1` ] = ` Array []` ;
153
158
154
- exports [` Config Options should work Config – Context – Loader { Object } : errors 1` ] = ` Array []` ;
159
+ exports [` "config" option should work with "string" value (path to directory with the configuration): warnings 1` ] = ` Array []` ;
155
160
156
- exports [` Config Options should work Config – Context – Loader { Object } : warnings 1` ] = ` Array []` ;
157
-
158
- exports [` Config Options should work if Config not found: css 1` ] = `
161
+ exports [` "config" option should work with "string" value and respect all options: css 1` ] = `
159
162
"a {
160
- color : black ;
163
+ color : black
161
164
}
162
165
163
- a {
164
- color : red ;
165
- }
166
-
167
- a {
168
- color : green ;
169
- }
170
-
171
- a {
172
- color : blue ;
173
- }
174
-
175
- .class {
176
- - x - border - color : blue blue * ;
177
- - x - color : * #fafafa ;
178
- }
179
-
180
- .class-foo {
181
- - z - border - color : blue blue * ;
182
- - z - color : * #fafafa ;
183
- }
184
-
185
- .phone {
186
- & _title {
187
- width: 500px ;
188
-
189
- @media (max - width : 500px ) {
190
- width: auto ;
191
- }
192
-
193
- body .is_dark & {
194
- color: white ;
195
- }
196
- }
197
-
198
- img {
199
- display: block ;
200
- }
201
- }
202
- "
166
+ /*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlLnNzcyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTtFQUNFO0FBREYiLCJmaWxlIjoic3R5bGUuY3NzIiwic291cmNlc0NvbnRlbnQiOlsiYVxuICBjb2xvcjogYmxhY2tcbiJdfQ== */"
203
167
` ;
204
168
205
- exports [` Config Options should work if Config not found : errors 1` ] = ` Array []` ;
169
+ exports [` "config" option should work with "string" value and respect all options : errors 1` ] = ` Array []` ;
206
170
207
- exports [` Config Options should work if Config not found : warnings 1` ] = ` Array []` ;
171
+ exports [` "config" option should work with "string" value and respect all options : warnings 1` ] = ` Array []` ;
208
172
209
- exports [` Config Options should work package.json - { Object } - Process CSS: css 1` ] = `
210
- ".import {
211
- color : red ;
212
- }
173
+ exports [` "config" option should work with "true" value: css 1` ] = `
174
+ "a { color : rgba (0 , 0 , 0 , 1.0 ) }
213
175
214
- .test {
215
- color : blue ;
176
+ .foo {
177
+ float : right ;
216
178
}
217
179
"
218
180
` ;
219
181
220
- exports [` Config Options should work package.json - { Object } - Process CSS : errors 1` ] = ` Array []` ;
182
+ exports [` "config" option should work with "true" value : errors 1` ] = ` Array []` ;
221
183
222
- exports [` Config Options should work package.json - { Object } - Process CSS : warnings 1` ] = ` Array []` ;
184
+ exports [` "config" option should work with "true" value : warnings 1` ] = ` Array []` ;
223
185
224
- exports [` Config Options should work postcss.config.js - { Array } - Process CSS: css 1` ] = `
225
- ".import {
226
- color : red ;
186
+ exports [` "config" option should work with the "postcssOptions" option: css 1` ] = `
187
+ "a { color : rgba (0 , 0 , 0 , 1.0 ) }
188
+
189
+ [dir=ltr] .foo { float : right ;
227
190
}
228
191
229
- .test {
230
- color : cyan ;
192
+ [dir=rtl] .foo {
193
+ float : left ;
231
194
}
232
195
"
233
196
` ;
234
197
235
- exports [` Config Options should work postcss.config.js - { Array } - Process CSS : errors 1` ] = ` Array []` ;
198
+ exports [` "config" option should work with the "postcssOptions" option : errors 1` ] = ` Array []` ;
236
199
237
- exports [` Config Options should work postcss.config.js - { Array } - Process CSS : warnings 1` ] = ` Array []` ;
200
+ exports [` "config" option should work with the "postcssOptions" option : warnings 1` ] = ` Array []` ;
238
201
239
- exports [` Config Options should work postcss.config.js - { Object } - Process CSS: css 1` ] = `
240
- ".import {
241
- color : red ;
242
- }
202
+ exports [` "config" option should work without the specified value: css 1` ] = `
203
+ "a { color : rgba (0 , 0 , 0 , 1.0 ) }
243
204
244
- .test {
245
- color : blue ;
205
+ .foo {
206
+ float : right ;
246
207
}
247
208
"
248
209
` ;
249
210
250
- exports [` Config Options should work postcss.config.js - { Object } - Process CSS : errors 1` ] = ` Array []` ;
211
+ exports [` "config" option should work without the specified value : errors 1` ] = ` Array []` ;
251
212
252
- exports [` Config Options should work postcss.config.js - { Object } - Process CSS : warnings 1` ] = ` Array []` ;
213
+ exports [` "config" option should work without the specified value : warnings 1` ] = ` Array []` ;
0 commit comments