Updated the test system
This commit is contained in:
9
test/clampNumber.test.js
Normal file
9
test/clampNumber.test.js
Normal file
@ -0,0 +1,9 @@
|
||||
const expect = require('expect');
|
||||
const {clampNumber} = require('./_30s.js');
|
||||
|
||||
test('clampNumber is a Function', () => {
|
||||
expect(clampNumber).toBeInstanceOf(Function);
|
||||
});
|
||||
test('Clamps num within the inclusive range specified by the boundary values a and b', () => {
|
||||
expect(clampNumber(2, 3, 5)).toBe(3);
|
||||
});
|
||||
Reference in New Issue
Block a user