Test files linted

This commit is contained in:
Angelos Chalaris
2018-08-03 10:39:26 +03:00
parent 4cd1c56387
commit 4f1e8b48b6
153 changed files with 754 additions and 463 deletions

View File

@ -10,24 +10,34 @@ test('without([2, 1, 2, 3], 1, 2) returns [3]', () => {
test('without([]) returns []', () => {
expect(without([])).toEqual([]);
});
test('without([3, 1, true, \'3\', true], \'3\', true) returns [3, 1]', () => {
test("without([3, 1, true, '3', true], '3', true) returns [3, 1]", () => {
expect(without([3, 1, true, '3', true], '3', true)).toEqual([3, 1]);
});
test('without(\'string\'.split(\'\'), \'s\', \'t\', \'g\') returns [\'r\', \'i\', \'n\']', () => {
test("without('string'.split(''), 's', 't', 'g') returns ['r', 'i', 'n']", () => {
expect(without('string'.split(''), 's', 't', 'g')).toEqual(['r', 'i', 'n']);
});
test('without() throws an error', () => {
expect(() => { without(); }).toThrow();
expect(() => {
without();
}).toThrow();
});
test('without(null) throws an error', () => {
expect(() => { without(null); }).toThrow();
expect(() => {
without(null);
}).toThrow();
});
test('without(undefined) throws an error', () => {
expect(() => { without(undefined); }).toThrow();
expect(() => {
without(undefined);
}).toThrow();
});
test('without(123) throws an error', () => {
expect(() => { without(123); }).toThrow();
expect(() => {
without(123);
}).toThrow();
});
test('without({}) throws an error', () => {
expect(() => { without({}); }).toThrow();
expect(() => {
without({});
}).toThrow();
});