Travis build: 1510 [cron]

This commit is contained in:
30secondsofcode
2018-02-02 20:17:05 +00:00
parent ef346fcc91
commit 2cbc41ddeb
10 changed files with 71 additions and 8 deletions

View File

@ -0,0 +1,2 @@
const getColonTimeFromDate = date => date.toTimeString().slice(0, 8);
module.exports = getColonTimeFromDate

View File

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

View File

@ -0,0 +1,5 @@
const getMeridiemSuffixOfInteger = num =>
num === 0 || num === 24
? 12 + 'am'
: num === 12 ? 12 + 'pm' : num < 12 ? num % 12 + 'am' : num % 12 + 'pm';
module.exports = getMeridiemSuffixOfInteger

View File

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

View File

@ -1,4 +1,4 @@
Test log for: Thu Feb 01 2018 20:16:56 GMT+0000 (UTC)
Test log for: Fri Feb 02 2018 20:16:58 GMT+0000 (UTC)
> 30-seconds-of-code@0.0.1 test /home/travis/build/Chalarangelo/30-seconds-of-code
> tape test/**/*.test.js | tap-spec
@ -474,11 +474,19 @@ Test log for: Thu Feb 01 2018 20:16:56 GMT+0000 (UTC)
✔ get is a Function
✔ Retrieve a property indicated by the selector from an object.
Testing getColonTimeFromDate
✔ getColonTimeFromDate is a Function
Testing getDaysDiffBetweenDates
✔ getDaysDiffBetweenDates is a Function
✔ Returns the difference in days between two dates
Testing getMeridiemSuffixOfInteger
✔ getMeridiemSuffixOfInteger is a Function
Testing getScrollPosition
✔ getScrollPosition is a Function
@ -1611,8 +1619,8 @@ Test log for: Thu Feb 01 2018 20:16:56 GMT+0000 (UTC)
✔ Works with multiple promises
total: 721
passing: 721
total: 723
passing: 723
duration: 2.3s