Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

node-schedule

Package Overview
Dependencies
Maintainers
4
Versions
45
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-schedule - npm Package Compare versions

Comparing version 0.3.0 to 0.5.0

test/es6/job-test.js

7

lib/schedule.js

@@ -35,2 +35,9 @@

// Check for generator
if (typeof this.job === 'function' && this.job.prototype.next) {
this.job = function() {
return this.next().value;
}.bind(this.job());
}
// define properties

@@ -37,0 +44,0 @@ Object.defineProperty(this, 'name', {

4

package.json
{
"name": "node-schedule",
"version": "0.3.0",
"version": "0.5.0",
"description": "A cron-like and not-cron-like job scheduler for Node.",

@@ -13,3 +13,3 @@ "keywords": [

"scripts": {
"test": "nodeunit && npm run lint",
"test": "nodeunit",
"lint": "eslint lib"

@@ -16,0 +16,0 @@ },

@@ -8,2 +8,8 @@

var es6;
try {
eval('(function* () {})()');
es6 = require('./es6/job-test')(schedule);
} catch (e) {}
var clock;

@@ -84,2 +90,13 @@

},
"Run job in generator": function(test) {
if (!es6) {
test.expect(0);
test.done();
return;
}
es6.jobInGenerator(test);
clock.tick(3250);
},
/* No jobs will run after this test for some reason - hide for now

@@ -86,0 +103,0 @@ "Won't run job if scheduled in the past": function(test) {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc