Skip to content
This repository was archived by the owner on Jul 26, 2025. It is now read-only.

Commit c7b9089

Browse files
committed
test: enhance level coverage
1 parent 0952643 commit c7b9089

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/filters/__tests__/level.test.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,3 +154,17 @@ test('3x1 rgba image, arrays as input', () => {
154154
[100, 100, 80, 50],
155155
]);
156156
});
157+
158+
test('parameters array length error', () => {
159+
const image = testUtils.createRgbaImage([
160+
[0, 10, 20, 50],
161+
[30, 40, 50, 50],
162+
[60, 70, 80, 50],
163+
]);
164+
165+
expect(() => {
166+
image.level({
167+
inputMin: [0],
168+
});
169+
}).toThrow('array length is not compatible with channel option');
170+
});

0 commit comments

Comments
 (0)