Tests for pull, pullBy, pullAtIndex, pullAtValue

This commit is contained in:
Angelos Chalaris
2018-02-04 21:02:32 +02:00
parent b19c621cad
commit 34f4a7e6fe
5 changed files with 28 additions and 8 deletions

View File

@ -5,9 +5,13 @@ test('Testing pullAtIndex', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof pullAtIndex === 'function', 'pullAtIndex is a Function');
let myArray = ['a', 'b', 'c', 'd'];
let pulled = pullAtIndex(myArray, [1, 3]);
t.deepEqual(myArray, [ 'a', 'c' ], 'Pulls the given values');
t.deepEqual(pulled, [ 'b', 'd' ], 'Pulls the given values');
//t.deepEqual(pullAtIndex(args..), 'Expected');
//t.equal(pullAtIndex(args..), 'Expected');
//t.false(pullAtIndex(args..), 'Expected');
//t.throws(pullAtIndex(args..), 'Expected');
t.end();
});
});