Test cleanup and fixes [s-t]

This commit is contained in:
Angelos Chalaris
2018-06-18 18:37:35 +03:00
parent ba3e684a27
commit 9cf2c4680c
53 changed files with 286 additions and 409 deletions

View File

@ -1,14 +1,12 @@
const expect = require('expect');
const takeRight = require('./takeRight.js');
test('takeRight is a Function', () => {
test('takeRight is a Function', () => {
expect(takeRight).toBeInstanceOf(Function);
});
test('Returns an array with n elements removed from the end', () => {
expect(takeRight([1, 2, 3], 2), [2).toEqual(3])
test('Returns an array with n elements removed from the end', () => {
expect(takeRight([1, 2, 3], 2)).toEqual([2, 3]);
});
test('Returns an array with n elements removed from the end', () => {
test('Returns an array with n elements removed from the end', () => {
expect(takeRight([1, 2, 3])).toEqual([3])
});