cron-job-manager
Version:
A wrapper Object for node-cron that allows you to manage multiple cron jobs at once.
20 lines (18 loc) • 576 B
JavaScript
/**
*
*/
let tests = {
'add' : './add',
'constructor' : './constructor' ,
'job deletion': './delete',
'update job': './update',
'start' : './startStop',
'fireOnTick': './fireOnTick'
};
for (test in tests) {
let currentTest = require(tests[test]);
if (currentTest.test instanceof Function) {
console.log(`running test: ${test}`)
currentTest.test.call(currentTest.context ? currentTest.context : this); //pass a context
}
}