Improve the readability of tomorrow.js (solved #775)

This commit is contained in:
Filip Danić
2018-10-17 11:36:41 +02:00
parent 4c926b26cd
commit 1e43dc7b89
3 changed files with 13 additions and 13 deletions

View File

@@ -4,6 +4,10 @@ const tomorrow = require('./tomorrow.js');
test('tomorrow is a Function', () => {
expect(tomorrow).toBeInstanceOf(Function);
});
test('Returns the correct type', () => {
expect(typeof tomorrow()).toBe('string');
});
const t1 = new Date(new Date().getFullYear(), new Date().getMonth(), new Date().getDate() + 1);
const t2 = new Date(tomorrow());
test('Returns the correct year', () => {