title: JavaScript: Node cron and node-schedule jobs execute immediately instead of in the future
body: <p>I am attempting to write a test-script, as part of a larger project which will allow me to schedule future text message alerts. In my script, I try to use both node packages cron and node-schedule. I configure a date object set to three minutes in the future. I use both packages to schedule the job. However, the messages are not sent at the right time, but are sent immediately. </p>
  
  <p>I want my code to execute at a set time in the future, does anyone know why the following code would not work?</p>
  
  <pre><code>var CronJob = require('cron').CronJob;
  var twilSms = require('./TwilSms');
  var schedule = require('node-schedule');
  
  var sendInThree = function(to,message) {
      var threeMinutes = 180000;
      var inThreeMinutes = new Date(Date.now()+threeMinutes);
      process.stdout.write("A text message should be sent at: \n" + inThreeMinutes.toString() + '\n');
  
      //TRIGGERS INSTANTLY
      var sched = schedule.scheduleJob(inThreeMinutes,twilSms.sendSms(to,
                     ('Did this message arrive at: ' + inThreeMinutes.toString() + '?')));
  
  
      //TRIGGERS INSTANTLY
      var cronSMS = new CronJob(inThreeMinutes,
                  twilSms.sendSms(to,
                      ('Did this message arrive at: ' + inThreeMinutes.toString() + '?')),
                  null, true);
  }
  
  
  sendInThree('13125555555');
  </code></pre>
  
  <p>NOTES: </p>
  
  <p>function twilSms.sendSms() workes as expected in the Node REPL.
  <br>
  I used a fake number only for uploading to SO.</p>
  
  <p>Thanks for any help.</p>