|
@@ -264,19 +264,19 @@ test('parses function call', (t) => {
|
264
|
264
|
|
265
|
265
|
test('parses mixin', (t) => {
|
266
|
266
|
t.plan(2);
|
267
|
|
- const result = parse('(@mixin centered ($width) :max-width $width :margin auto)');
|
|
267
|
+ const result = parse(
|
|
268
|
+ '(@mixin centered ($width) :max-width $width :margin auto)'
|
|
269
|
+ );
|
268
|
270
|
t.false(result instanceof ParserError);
|
269
|
271
|
if (!(result instanceof LexerError) && !(result instanceof ParserError)) {
|
270
|
272
|
t.deepEqual(result.tree, [
|
271
|
273
|
new AST.Mixin(
|
272
|
274
|
literalToken('centered'),
|
273
|
|
- [
|
274
|
|
- identifierNode('width'),
|
275
|
|
- ],
|
|
275
|
+ [identifierNode('width')],
|
276
|
276
|
[
|
277
|
277
|
new AST.Rule(
|
278
|
278
|
new AST.Property(propertyToken('max-width')),
|
279
|
|
- identifierNode('width'),
|
|
279
|
+ identifierNode('width')
|
280
|
280
|
),
|
281
|
281
|
new AST.Rule(
|
282
|
282
|
new AST.Property(propertyToken('margin')),
|