From: Jérôme Benoit Date: Sun, 3 Sep 2023 20:39:10 +0000 (+0200) Subject: test: improve min/max tests X-Git-Tag: v2.6.42~12 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=625449e060dbabfb63148692f080ca035d92ec93;p=poolifier.git test: improve min/max tests Signed-off-by: Jérôme Benoit --- diff --git a/tests/utils.test.js b/tests/utils.test.js index 2101891a..426985a2 100644 --- a/tests/utils.test.js +++ b/tests/utils.test.js @@ -315,12 +315,14 @@ describe('Utils test suite', () => { }) it('Verify min() behavior', () => { + expect(min()).toBe(Infinity) expect(min(1, 2)).toBe(1) expect(min(2, 1)).toBe(1) expect(min(1, 1)).toBe(1) }) it('Verify max() behavior', () => { + expect(max()).toBe(-Infinity) expect(max(1, 2)).toBe(2) expect(max(2, 1)).toBe(2) expect(max(1, 1)).toBe(1)