Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
GH-339 - Update dev deps and fix tests.
Updates for chai required a couple test changes. Also updated mocha.

Signed-off-by: Nick Campbell <nicholas.j.campbell@gmail.com>
  • Loading branch information
ncb000gt committed Aug 16, 2018
1 parent 4a16ee0 commit 08e197e
Show file tree
Hide file tree
Showing 3 changed files with 309 additions and 6 deletions.
303 changes: 303 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
@@ -1,7 +1,7 @@
{
"name": "cron",
"description": "Cron jobs for your node",
"version": "1.3.0",
"version": "1.3.1",
"author": "Nick Campbell <nicholas.j.campbell@gmail.com> (http://github.com/ncb000gt)",
"bugs": {
"url": "http://github.com/kelektiv/node-cron/issues"
Expand All @@ -18,8 +18,8 @@
"moment-timezone": "^0.5.x"
},
"devDependencies": {
"mocha": "~2.3.3",
"chai": "~3.4.0",
"mocha": "~5.1.x",
"chai": "~4.1.x",
"sinon": "~1.12.x"
},
"license": "MIT",
Expand Down
6 changes: 3 additions & 3 deletions tests/test-crontime.js
Expand Up @@ -134,7 +134,7 @@ describe('crontime', function () {
var next = ct._getNextDateFrom(start);

expect(next - start).to.be.lt(24 * 60 * 60 * 1000);
expect(next).to.be.gt(start);
expect(next._d).to.be.gt(start);
}
});

Expand All @@ -151,7 +151,7 @@ describe('crontime', function () {
nextDate.setHours(23);
var nextdt = ct._getNextDateFrom(nextDate);

expect(nextdt).to.be.gt(nextDate);
expect(nextdt._d).to.be.gt(nextDate);
expect(nextdt.hours() % 4).to.eql(0);
});

Expand All @@ -168,7 +168,7 @@ describe('crontime', function () {

var nextDate = new Date();
nextDate.setMonth(nextDate.getMonth() + 1);
expect(nextDate).to.be.gt(ct.source);
expect(nextDate).to.be.gt(ct.source._d);
var nextdt = ct._getNextDateFrom(nextDate);
expect(nextdt.isSame(nextDate)).to.be.true;
});
Expand Down

0 comments on commit 08e197e

Please sign in to comment.