rename js/x ts/x

This commit is contained in:
Thomas Ruoff
2020-08-26 22:36:27 +02:00
committed by Thomas Ruoff
parent 9853e31201
commit be1e22460d
23 changed files with 0 additions and 0 deletions

13
helpers/array.test.ts Normal file
View File

@@ -0,0 +1,13 @@
import { getNextSmaller, getNextBigger } from './array'
test('getPreviousInOrder', () => {
const result = getNextSmaller([3, 1, 2, 0, 8, 9, 10], 5)
expect(result).toEqual(3)
})
test('getNextInOrder', () => {
const result = getNextBigger([7, 8, 9, 3, 1, 2], 4)
expect(result).toEqual(7)
})