Skip to content

Commit 88e1852

Browse files
committed
Update test matchers
1 parent ec36605 commit 88e1852

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

test/no-empty-string-alt.test.js

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,7 @@ describe("GH003: No Empty String Alt", () => {
1111
];
1212

1313
const results = await runTest(strings, noEmptyStringAltRule);
14-
15-
for (const result of results) {
16-
expect(result).not.toBeDefined();
17-
}
14+
expect(results).toHaveLength(0);
1815
});
1916
test("html image", async () => {
2017
const strings = [
@@ -23,10 +20,7 @@ describe("GH003: No Empty String Alt", () => {
2320
];
2421

2522
const results = await runTest(strings, noEmptyStringAltRule);
26-
27-
for (const result of results) {
28-
expect(result).not.toBeDefined();
29-
}
23+
expect(results).toHaveLength(0);
3024
});
3125
});
3226
describe("failures", () => {

0 commit comments

Comments
 (0)