Files
archived-nodemon/test/fork/run.test.js
Remy Sharp abc27cd5ca Correct signal passing. Fixes #232.
Also more linting, tweaks to FAQ & contributing and added .jshint file.

Also adds test for signal test (though needs mocha to timeout at 15 seconds!)
2013-12-10 00:06:25 +00:00

24 lines
542 B
JavaScript

/*global describe:true, it: true */
var assert = require('assert'),
utils = require('../utils'),
appjs = utils.appjs,
run = utils.run;
describe('nodemon fork', function () {
it('should start a fork', function (done) {
var p = run(appjs, {
error: function (data) {
p.send('quit');
done(new Error(data));
}
});
p.on('message', function (event) {
if (event.type === 'start') {
p.send('quit');
assert(true, 'nodemon started');
done();
}
});
});
});