From: Jérôme Benoit Date: Wed, 3 Jul 2024 21:15:57 +0000 (+0200) Subject: refactor(test): code cleanups X-Git-Tag: ocpp-server@v1.4.0~24 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=b53037c097bf8412831281229234e814aaae82a9;p=e-mobility-charging-stations-simulator.git refactor(test): code cleanups Signed-off-by: Jérôme Benoit --- diff --git a/tests/utils/Utils.test.ts b/tests/utils/Utils.test.ts index 11b9973e..adf8ffea 100644 --- a/tests/utils/Utils.test.ts +++ b/tests/utils/Utils.test.ts @@ -387,16 +387,8 @@ await describe('Utils test suite', async () => { }) await it('Verify isArraySorted()', () => { - expect( - isArraySorted([], (a, b) => { - return a - b - }) - ).toBe(true) - expect( - isArraySorted([1], (a, b) => { - return a - b - }) - ).toBe(true) + expect(isArraySorted([], (a, b) => a - b)).toBe(true) + expect(isArraySorted([1], (a, b) => a - b)).toBe(true) expect(isArraySorted([1, 2, 3, 4, 5], (a, b) => a - b)).toBe(true) expect(isArraySorted([1, 2, 3, 5, 4], (a, b) => a - b)).toBe(false) expect(isArraySorted([2, 1, 3, 4, 5], (a, b) => a - b)).toBe(false)