fix conflicts

This commit is contained in:
Rohit Tanwar
2018-02-17 22:10:34 +05:30
55 changed files with 246 additions and 367 deletions

View File

@ -1,2 +1,2 @@
const all = arr => arr.every(Boolean);
const all = (arr, fn = Boolean) => arr.every(fn);
module.exports = all;

View File

@ -11,6 +11,8 @@ test('Testing all', (t) => {
t.false(all([undefined,1]), 'Returns false for arrays with undefined');
t.false(all([null,1]), 'Returns false for arrays with null');
t.false(all(['',1]), 'Returns false for arrays with empty strings');
t.true(all([4,1,2,3], x => x >= 1), 'Returns true with predicate function');
t.false(all([0,1], x => x >= 1), 'Returns false with a predicate function');
//t.deepEqual(all(args..), 'Expected');
//t.equal(all(args..), 'Expected');
//t.false(all(args..), 'Expected');

View File

@ -1,2 +0,0 @@
const allBy = (arr, fn) => arr.every(fn);
module.exports = allBy;

View File

@ -1,15 +0,0 @@
const test = require('tape');
const allBy = require('./allBy.js');
test('Testing allBy', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof allBy === 'function', 'allBy is a Function');
t.true(allBy([4,1,2,3], x => x >= 1), 'Returns true with predicate function');
t.false(allBy([0,1], x => x >= 1), 'Returns false with a predicate function');
//t.deepEqual(allBy(args..), 'Expected');
//t.equal(allBy(args..), 'Expected');
//t.false(allBy(args..), 'Expected');
//t.throws(allBy(args..), 'Expected');
t.end();
});

View File

@ -1,2 +1,2 @@
const any = arr => arr.some(Boolean);
const any = (arr, fn = Boolean) => arr.some(fn);
module.exports = any;

View File

@ -8,6 +8,8 @@ test('Testing any', (t) => {
t.true(any([0,1,2,3]), 'Returns true for arrays with at least one truthy value');
t.false(any([0,0]), 'Returns false for arrays with no truthy values');
t.false(any([NaN,0,undefined,null,'']), 'Returns false for arrays with no truthy values');
t.true(any([4,1,0,3], x => x >= 1), 'Returns true with predicate function');
t.false(any([0,1], x => x < 0), 'Returns false with a predicate function');
//t.deepEqual(any(args..), 'Expected');
//t.equal(any(args..), 'Expected');
//t.false(any(args..), 'Expected');

View File

@ -1,2 +0,0 @@
const anyBy = (arr, fn) => arr.some(fn);
module.exports = anyBy;

View File

@ -1,15 +0,0 @@
const test = require('tape');
const anyBy = require('./anyBy.js');
test('Testing anyBy', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof anyBy === 'function', 'anyBy is a Function');
t.true(anyBy([4,1,0,3], x => x >= 1), 'Returns true with predicate function');
t.false(anyBy([0,1], x => x < 0), 'Returns false with a predicate function');
//t.deepEqual(anyBy(args..), 'Expected');
//t.equal(anyBy(args..), 'Expected');
//t.false(anyBy(args..), 'Expected');
//t.throws(anyBy(args..), 'Expected');
t.end();
});

View File

@ -5,9 +5,10 @@ test('Testing arrayToHtmlList', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof arrayToHtmlList === 'function', 'arrayToHtmlList is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(arrayToHtmlList(args..), 'Expected');
//t.equal(arrayToHtmlList(args..), 'Expected');
//t.false(arrayToHtmlList(args..), 'Expected');
//t.throws(arrayToHtmlList(args..), 'Expected');
t.end();
});
});

View File

@ -5,22 +5,19 @@ test('Testing chainAsync', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof chainAsync === 'function', 'chainAsync is a Function');
//t.deepEqual(chainAsync(args..), 'Expected');
// chainAsync([
// next => {
// next();
// },
// next => {
// (() =>{
// next()
// })();
// },
// next => {
// t.pass("Calls all functions in an array");
// next();
// }
// ]);
//
chainAsync([
next => {
next();
},
next => {
(() => {
next();
})();
},
next => {
t.pass("Calls all functions in an array");
}
]);
// // Ensure we wait for the 2nd assertion to be made
// t.plan(2);

View File

@ -5,9 +5,10 @@ test('Testing createElement', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof createElement === 'function', 'createElement is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(createElement(args..), 'Expected');
//t.equal(createElement(args..), 'Expected');
//t.false(createElement(args..), 'Expected');
//t.throws(createElement(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing createEventHub', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof createEventHub === 'function', 'createEventHub is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(createEventHub(args..), 'Expected');
//t.equal(createEventHub(args..), 'Expected');
//t.false(createEventHub(args..), 'Expected');
//t.throws(createEventHub(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing currentURL', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof currentURL === 'function', 'currentURL is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(currentURL(args..), 'Expected');
//t.equal(currentURL(args..), 'Expected');
//t.false(currentURL(args..), 'Expected');
//t.throws(currentURL(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing debounce', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof debounce === 'function', 'debounce is a Function');
debounce(() => {t.pass('Works as expected');}, 250);
//t.deepEqual(debounce(args..), 'Expected');
//t.equal(debounce(args..), 'Expected');
//t.false(debounce(args..), 'Expected');
//t.throws(debounce(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing defaults', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof defaults === 'function', 'defaults is a Function');
t.deepEqual(defaults({ a: 1 }, { b: 2 }, { b: 6 }, { a: 3 }), { a: 1, b: 2 }, 'Assigns default values for undefined properties');
//t.deepEqual(defaults(args..), 'Expected');
//t.equal(defaults(args..), 'Expected');
//t.false(defaults(args..), 'Expected');
//t.throws(defaults(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing defer', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof defer === 'function', 'defer is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(defer(args..), 'Expected');
//t.equal(defer(args..), 'Expected');
//t.false(defer(args..), 'Expected');
//t.throws(defer(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,16 @@ test('Testing delay', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof delay === 'function', 'delay is a Function');
delay(
function(text) {
t.equals(text, 'test', 'Works as expecting, passing arguments properly');
},
1000,
'test'
);
//t.deepEqual(delay(args..), 'Expected');
//t.equal(delay(args..), 'Expected');
//t.false(delay(args..), 'Expected');
//t.throws(delay(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing getScrollPosition', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof getScrollPosition === 'function', 'getScrollPosition is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(getScrollPosition(args..), 'Expected');
//t.equal(getScrollPosition(args..), 'Expected');
//t.false(getScrollPosition(args..), 'Expected');
//t.throws(getScrollPosition(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing getStyle', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof getStyle === 'function', 'getStyle is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(getStyle(args..), 'Expected');
//t.equal(getStyle(args..), 'Expected');
//t.false(getStyle(args..), 'Expected');
//t.throws(getStyle(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing hasFlags', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof hasFlags === 'function', 'hasFlags is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(hasFlags(args..), 'Expected');
//t.equal(hasFlags(args..), 'Expected');
//t.false(hasFlags(args..), 'Expected');
//t.throws(hasFlags(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing hashBrowser', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof hashBrowser === 'function', 'hashBrowser is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(hashBrowser(args..), 'Expected');
//t.equal(hashBrowser(args..), 'Expected');
//t.false(hashBrowser(args..), 'Expected');
//t.throws(hashBrowser(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing hide', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof hide === 'function', 'hide is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(hide(args..), 'Expected');
//t.equal(hide(args..), 'Expected');
//t.false(hide(args..), 'Expected');
//t.throws(hide(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing mostPerformant', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof mostPerformant === 'function', 'mostPerformant is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(mostPerformant(args..), 'Expected');
//t.equal(mostPerformant(args..), 'Expected');
//t.false(mostPerformant(args..), 'Expected');
//t.throws(mostPerformant(args..), 'Expected');
t.end();
});
});

View File

@ -1,2 +1,2 @@
const none = arr => !arr.some(Boolean);
const none = (arr, fn = Boolean) => !arr.some(fn);
module.exports = none;

View File

@ -7,6 +7,8 @@ test('Testing none', (t) => {
t.true(typeof none === 'function', 'none is a Function');
t.true(none([0,undefined,NaN,null,'']), 'Returns true for arrays with no truthy values');
t.false(none([0,1]), 'Returns false for arrays with at least one truthy value');
t.true(none([4,1,0,3], x => x < 0), 'Returns true with a predicate function');
t.false(none([0,1,2], x => x === 1), 'Returns false with predicate function');
//t.deepEqual(none(args..), 'Expected');
//t.equal(none(args..), 'Expected');
//t.false(none(args..), 'Expected');

View File

@ -1,2 +0,0 @@
const noneBy = (arr, fn) => !arr.some(fn);
module.exports = noneBy;

View File

@ -1,15 +0,0 @@
const test = require('tape');
const noneBy = require('./noneBy.js');
test('Testing noneBy', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof noneBy === 'function', 'noneBy is a Function');
t.true(noneBy([4,1,0,3], x => x < 0), 'Returns true with a predicate function');
t.false(noneBy([0,1,2], x => x === 1), 'Returns false with predicate function');
//t.deepEqual(noneBy(args..), 'Expected');
//t.equal(noneBy(args..), 'Expected');
//t.false(noneBy(args..), 'Expected');
//t.throws(noneBy(args..), 'Expected');
t.end();
});

View File

@ -5,9 +5,10 @@ test('Testing off', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof off === 'function', 'off is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(off(args..), 'Expected');
//t.equal(off(args..), 'Expected');
//t.false(off(args..), 'Expected');
//t.throws(off(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing on', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof on === 'function', 'on is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(on(args..), 'Expected');
//t.equal(on(args..), 'Expected');
//t.false(on(args..), 'Expected');
//t.throws(on(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing onUserInputChange', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof onUserInputChange === 'function', 'onUserInputChange is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(onUserInputChange(args..), 'Expected');
//t.equal(onUserInputChange(args..), 'Expected');
//t.false(onUserInputChange(args..), 'Expected');
//t.throws(onUserInputChange(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing once', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof once === 'function', 'once is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(once(args..), 'Expected');
//t.equal(once(args..), 'Expected');
//t.false(once(args..), 'Expected');
//t.throws(once(args..), 'Expected');
t.end();
});
});

View File

@ -8,8 +8,8 @@ test('Testing randomHexColorCode', (t) => {
//t.deepEqual(randomHexColorCode(args..), 'Expected');
t.equal(randomHexColorCode().length, 7);
t.true(randomHexColorCode().startsWith('#'),'The color code starts with "#"');
t.true(randomHexColorCode().slice(1).match(/[^0123456789abcdef]/i) === null)
t.true(randomHexColorCode().slice(1).match(/[^0123456789abcdef]/i) === null,'The color code contains only valid hex-digits');
//t.false(randomHexColorCode(args..), 'Expected');
//t.throws(randomHexColorCode(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing setStyle', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof setStyle === 'function', 'setStyle is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(setStyle(args..), 'Expected');
//t.equal(setStyle(args..), 'Expected');
//t.false(setStyle(args..), 'Expected');
//t.throws(setStyle(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing show', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof show === 'function', 'show is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(show(args..), 'Expected');
//t.equal(show(args..), 'Expected');
//t.false(show(args..), 'Expected');
//t.throws(show(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,13 @@ test('Testing sleep', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof sleep === 'function', 'sleep is a Function');
async function sleepyWork() {
await sleep(1000);
t.pass('Works as expected');
}
//t.deepEqual(sleep(args..), 'Expected');
//t.equal(sleep(args..), 'Expected');
//t.false(sleep(args..), 'Expected');
//t.throws(sleep(args..), 'Expected');
t.end();
});
});

View File

@ -1,24 +1,20 @@
Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Test log for: Fri Feb 16 2018 20:23:57 GMT+0000 (UTC)
> 30-seconds-of-code@0.0.1 test R:\github\30-seconds-of-code
> 30-seconds-of-code@0.0.2 test /home/travis/build/Chalarangelo/30-seconds-of-code
> tape test/**/*.test.js | tap-spec
Testing all
all is a Function
Returns true for arrays with no falsey values
Returns false for arrays with 0
Returns false for arrays with NaN
Returns false for arrays with undefined
Returns false for arrays with null
Returns false for arrays with empty strings
Testing allBy
√ allBy is a Function
√ Returns true with predicate function
√ Returns false with a predicate function
all is a Function
Returns true for arrays with no falsey values
Returns false for arrays with 0
Returns false for arrays with NaN
Returns false for arrays with undefined
Returns false for arrays with null
Returns false for arrays with empty strings
✔ Returns true with predicate function
✔ Returns false with a predicate function
Testing anagrams
@ -29,16 +25,12 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing any
any is a Function
Returns true for arrays with at least one truthy value
Returns false for arrays with no truthy values
Returns false for arrays with no truthy values
Testing anyBy
√ anyBy is a Function
√ Returns true with predicate function
√ Returns false with a predicate function
any is a Function
Returns true for arrays with at least one truthy value
Returns false for arrays with no truthy values
Returns false for arrays with no truthy values
✔ Returns true with predicate function
✔ Returns false with a predicate function
Testing approximatelyEqual
@ -50,7 +42,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing arrayToHtmlList
arrayToHtmlList is a Function
arrayToHtmlList is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing ary
@ -71,18 +64,18 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing average
average is a Function
average(true) returns 0
average(false) returns 1
average(9, 1) returns 5
average(153, 44, 55, 64, 71, 1122, 322774, 2232, 23423, 234, 3631) returns 32163.909090909092
average(1, 2, 3) returns 2
average(null) returns 0
average(1, 2, 3) returns NaN
average(String) returns NaN
average({ a: 123}) returns NaN
average([undefined, 0, string]) returns NaN
average([1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 1122, 32124, 23232]) takes less than 2s to run
average is a Function
average(true) returns 0
average(false) returns 1
average(9, 1) returns 5
average(153, 44, 55, 64, 71, 1122, 322774, 2232, 23423, 234, 3631) returns 32163.909090909092
average(1, 2, 3) returns 2
average(null) returns 0
average(1, 2, 3) returns NaN
average(String) returns NaN
average({ a: 123}) returns NaN
average([undefined, 0, string]) returns NaN
average([1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 1122, 32124, 23232]) takes less than 2s to run
Testing averageBy
@ -180,7 +173,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing chainAsync
chainAsync is a Function
chainAsync is a Function
✔ Calls all functions in an array
Testing chunk
@ -279,15 +273,18 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing createElement
createElement is a Function
createElement is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing createEventHub
createEventHub is a Function
createEventHub is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing currentURL
currentURL is a Function
currentURL is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing curry
@ -318,11 +315,13 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing defaults
defaults is a Function
defaults is a Function
✔ Assigns default values for undefined properties
Testing defer
defer is a Function
defer is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing degreesToRads
@ -576,11 +575,13 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing getScrollPosition
getScrollPosition is a Function
getScrollPosition is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing getStyle
getStyle is a Function
getStyle is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing getType
@ -609,11 +610,13 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing hasFlags
hasFlags is a Function
hasFlags is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing hashBrowser
hashBrowser is a Function
hashBrowser is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing hashNode
@ -640,7 +643,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing hide
hide is a Function
hide is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing howManyTimes
@ -1086,7 +1090,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing mostPerformant
mostPerformant is a Function
mostPerformant is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing negate
@ -1095,15 +1100,11 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing none
none is a Function
Returns true for arrays with no truthy values
Returns false for arrays with at least one truthy value
Testing noneBy
√ noneBy is a Function
√ Returns true with a predicate function
√ Returns false with predicate function
none is a Function
Returns true for arrays with no truthy values
Returns false for arrays with at least one truthy value
✔ Returns true with a predicate function
✔ Returns false with predicate function
Testing nthArg
@ -1135,7 +1136,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing off
off is a Function
off is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing omit
@ -1149,15 +1151,18 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing on
on is a Function
on is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing once
once is a Function
onUserInputChange is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing onUserInputChange
onUserInputChange is a Function
once is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing orderBy
@ -1299,10 +1304,10 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing randomHexColorCode
randomHexColorCode is a Function
should be equal
The color code starts with "#"
√ should be truthy
randomHexColorCode is a Function
should be equal
The color code starts with "#"
✔ The color code contains only valid hex-digits
Testing randomIntArrayInRange
@ -1435,7 +1440,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing setStyle
setStyle is a Function
setStyle is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing shallowClone
@ -1445,7 +1451,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing show
show is a Function
show is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing shuffle
@ -1586,12 +1593,13 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing throttle
throttle is a Function
throttle is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing times
times is a Function
√ Runs a function the specified amount of times
timeTaken is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing timeTaken
@ -1656,18 +1664,8 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing toSafeInteger
toSafeInteger is a Function
√ Number(toSafeInteger(3.2)) is a number
√ Converts a value to a safe integer
√ toSafeInteger('4.2') returns 4
√ toSafeInteger(4.6) returns 5
√ toSafeInteger([]) returns 0
√ isNaN(toSafeInteger([1.5, 3124])) is true
√ isNaN(toSafeInteger('string')) is true
√ isNaN(toSafeInteger({})) is true
√ isNaN(toSafeInteger()) is true
√ toSafeInteger(Infinity) returns 9007199254740991
√ toSafeInteger(3.2) takes less than 2s to run
toggleClass is a Function
✔ Tested by @chalarangelo on 16/02/2018
Testing toSnakeCase
@ -1890,16 +1888,17 @@ Test log for: Sat Feb 17 2018 21:51:17 GMT+0530 (India Standard Time)
Testing zipWith
zipWith is a Function
√ Runs the function provided
Runs promises in series
Sends a GET request
√ Works with multiple promises
√ Sends a POST request
zipWith is a Function
✔ Sends a GET request
Runs the function provided
Sends a POST request
✔ Runs promises in series
✔ Works as expecting, passing arguments properly
✔ Works with multiple promises
total: 951
passing: 951
duration: 5.6s
total: 970
passing: 970
duration: 2.5s

View File

@ -5,9 +5,10 @@ test('Testing throttle', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof throttle === 'function', 'throttle is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(throttle(args..), 'Expected');
//t.equal(throttle(args..), 'Expected');
//t.false(throttle(args..), 'Expected');
//t.throws(throttle(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing timeTaken', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof timeTaken === 'function', 'timeTaken is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(timeTaken(args..), 'Expected');
//t.equal(timeTaken(args..), 'Expected');
//t.false(timeTaken(args..), 'Expected');
//t.throws(timeTaken(args..), 'Expected');
t.end();
});
});

View File

@ -5,9 +5,10 @@ test('Testing toggleClass', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof toggleClass === 'function', 'toggleClass is a Function');
t.pass('Tested by @chalarangelo on 16/02/2018');
//t.deepEqual(toggleClass(args..), 'Expected');
//t.equal(toggleClass(args..), 'Expected');
//t.false(toggleClass(args..), 'Expected');
//t.throws(toggleClass(args..), 'Expected');
t.end();
});
});