Permalink
Browse files

[refactor tests] Remove unused mocks

  • Loading branch information...
1 parent 1c91857 commit ca6198bafd58268bf2547afeb70cdcc2a629e724 @indexzero indexzero committed Jul 6, 2012
Showing with 0 additions and 56 deletions.
  1. +0 −12 test/helpers/mocks/child-process.js
  2. +0 −25 test/helpers/mocks/monitor.js
  3. +0 −19 test/helpers/mocks/stream.js
@@ -1,12 +0,0 @@
-var util = require('util'),
- EventEmitter2 = require('eventemitter2').EventEmitter2,
- StreamMock = require('./stream').StreamMock;
-
-var ChildProcessMock = exports.ChildProcessMock = function () {
- EventEmitter2.call(this);
-
- this.stdout = new StreamMock();
- this.stderr = new StreamMock();
-};
-util.inherits(ChildProcessMock, EventEmitter2);
-
@@ -1,25 +0,0 @@
-var util = require('util'),
- broadway = require('broadway'),
- ChildProcessMock = require('./child-process').ChildProcessMock;
-
-var MonitorMock = exports.MonitorMock = function (options) {
- broadway.App.call(this, options);
-
- this.child = new ChildProcessMock();
- this.running = false;
-};
-util.inherits(MonitorMock, broadway.App);
-
-MonitorMock.prototype.__defineGetter__('data', function () {
- return {
- uid: '_uid',
- command: 'node'
- }
-});
-
-MonitorMock.prototype.kill = MonitorMock.prototype.stop = function (forceStop) {
- this.running = false;
-
- this.emit('stop');
-};
-
@@ -1,19 +0,0 @@
-var util = require('util'),
- EventEmitter2 = require('eventemitter2').EventEmitter2;
-
-var StreamMock = exports.StreamMock = function () {
- EventEmitter2.call(this);
-
- this.contents = [];
- this.closed = false;
-};
-util.inherits(StreamMock, EventEmitter2);
-
-StreamMock.prototype.write = function (data) {
- this.contents.push(data);
-};
-
-StreamMock.prototype.close = StreamMock.prototype.end = function () {
- this.closed = true;
-};
-

0 comments on commit ca6198b

Please sign in to comment.