Skip to content

Commit 1bce741

Browse files
committed
test: for issue #183 with rule
1 parent 7152277 commit 1bce741

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

test/test.js

+7-1
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,18 @@ test('it change circular reference', t => {
1212
t.is(processing(value), expected);
1313
});
1414

15-
test('it should not throw error', t => {
15+
test('it should not throw error if comment exists', t => {
1616
const expected = ':root{ --from: 1; /* comment */ }';
1717
const value = ':root{ --from: 1; /* comment */ }';
1818
t.is(processing(value), expected);
1919
});
2020

21+
test('it should not throw error if comment exists with rule', t => {
22+
const expected = ':root{ --from: 1; /* comment */ } @for $i from 1 to 2';
23+
const value = ':root{ --from: 1; /* comment */ } @for $i from var(--from) to 2';
24+
t.is(processing(value), expected);
25+
});
26+
2127
test('it change first properties for @for', t => {
2228
const expected = ':root{ --from: 1; } @for $i from 1 to 2';
2329
const value = ':root{ --from: 1; } @for $i from var(--from) to 2';

0 commit comments

Comments
 (0)