From ca8c747c8d4078d55bf768276dc1e88ed59e0d41 Mon Sep 17 00:00:00 2001 From: Angelos Chalaris Date: Sat, 10 Feb 2018 17:11:48 +0200 Subject: [PATCH] Revert changes from #602 The changes in #602 would break the test, as it was comparing today to tomorrow. The original test worked just fine and the cron job that run on Travis proves that the `t1` assignment was valid and working. --- test/tomorrow/tomorrow.test.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/tomorrow/tomorrow.test.js b/test/tomorrow/tomorrow.test.js index a6e6dc9bc..a9f77a544 100644 --- a/test/tomorrow/tomorrow.test.js +++ b/test/tomorrow/tomorrow.test.js @@ -5,7 +5,7 @@ test('Testing tomorrow', (t) => { //For more information on all the methods supported by tape //Please go to https://github.com/substack/tape t.true(typeof tomorrow === 'function', 'tomorrow is a Function'); - const t1 = new Date(); + const t1 = new Date(new Date().getFullYear(), new Date().getMonth(), new Date().getDate() + 1); const t2 = new Date(tomorrow()); t.equal(t1.getFullYear(), t2.getFullYear(), 'Returns the correct year'); t.equal(t1.getMonth(), t2.getMonth(), 'Returns the correct month');