cron-parser
Advanced tools
Comparing version 2.1.0 to 2.1.1
@@ -5,3 +5,3 @@ { | ||
"description": "Node.js library for parsing crontab instructions", | ||
"version": "2.1.0", | ||
"version": "2.1.1", | ||
"keywords": ["cron", "crontab", "parser"], | ||
@@ -8,0 +8,0 @@ "dependencies": {}, |
@@ -331,3 +331,3 @@ 'use strict'; | ||
} | ||
} | ||
}; | ||
@@ -480,2 +480,5 @@ | ||
continue; | ||
} else if (!matchSchedule(currentHour - 1, this._fields.hour)) { | ||
currentDate.addHour(); | ||
continue; | ||
} | ||
@@ -482,0 +485,0 @@ } else if (this._dstEnd === currentHour) { |
{ | ||
"name": "cron-parser", | ||
"version": "2.1.0", | ||
"version": "2.1.1", | ||
"description": "Node.js library for parsing crontab instructions", | ||
@@ -5,0 +5,0 @@ "main": "lib/parser.js", |
@@ -26,2 +26,15 @@ var test = require('tap').test; | ||
interval = CronExpression.parse('30 2 * * *', options); | ||
t.ok(interval, 'Interval parsed'); | ||
date = interval.next(); | ||
t.equal(date.getMinutes(), 30, '30 Minutes'); | ||
t.equal(date.getHours(), 2, '2 AM'); | ||
t.equal(date.getDate(), 27, 'on the 27th'); | ||
date = interval.next(); | ||
t.equal(date.getMinutes(), 30, '30 Minutes'); | ||
t.equal(date.getHours(), 2, '2 AM'); | ||
t.equal(date.getDate(), 28, 'on the 28th'); | ||
interval = CronExpression.parse('0 3 * * *', options); | ||
@@ -28,0 +41,0 @@ t.ok(interval, 'Interval parsed'); |
94519
23
1618