Skip to content

Commit bf4a7c0

Browse files
committed
test(deps): require nested CSS rule visitation before exit
1 parent a68f928 commit bf4a7c0

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tests/dependency-postcss.test.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,8 @@ describe('PostCSS dependency regressions', function () {
100100
const asyncResult = await postcss([plugin(asyncOrder)]).process(css, options);
101101
assert.strictEqual(asyncResult.css, sync);
102102
assert.deepStrictEqual(asyncOrder, syncOrder);
103-
assert.ok(syncOrder.indexOf('.widget .value span') < syncOrder.indexOf('exit'));
103+
const nestedVisit = syncOrder.indexOf('.widget .value span');
104+
assert.ok(nestedVisit >= 0 && nestedVisit < syncOrder.indexOf('exit'));
104105
assert.ok(sync.includes('.widget .value span'));
105106
});
106107

0 commit comments

Comments
 (0)