Skip to content

Commit 196ee2e

Browse files
committed
fix
1 parent 0f95d95 commit 196ee2e

File tree

1 file changed

+16
-18
lines changed
  • packages/css-parser-algorithms/test/cases/component-value

1 file changed

+16
-18
lines changed

packages/css-parser-algorithms/test/cases/component-value/0001.mjs

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -22,27 +22,25 @@ test('component-value', (t) => {
2222
},
2323
];
2424

25-
cases.forEach((testCase, index) => {
26-
t.test(index, () => {
27-
let didError = false;
25+
cases.forEach((testCase) => {
26+
let didError = false;
2827

29-
const result = parseComponentValue(testCase.tokens, {
30-
onParseError: (err) => {
31-
didError = true;
28+
const result = parseComponentValue(testCase.tokens, {
29+
onParseError: (err) => {
30+
didError = true;
3231

33-
if (testCase.expectSuccess) {
34-
throw err;
35-
}
36-
},
37-
});
32+
if (testCase.expectSuccess) {
33+
throw err;
34+
}
35+
},
36+
});
3837

39-
if (testCase.expectSuccess && !result) {
40-
throw new Error('Expected test to pass and have a result');
41-
}
38+
if (testCase.expectSuccess && !result) {
39+
throw new Error('Expected test to pass and have a result');
40+
}
4241

43-
if (!testCase.expectSuccess && !didError) {
44-
throw new Error('Expected test to fail');
45-
}
46-
});
42+
if (!testCase.expectSuccess && !didError) {
43+
throw new Error('Expected test to fail');
44+
}
4745
});
4846
});

0 commit comments

Comments
 (0)