eventric-testing
Version:
Testing helpers for eventric.js
26 lines (19 loc) • 554 B
JavaScript
var StubFactory;
StubFactory = (function() {
function StubFactory() {
this.stub = function() {
return function() {};
};
this.configureReturnValue = function() {
throw new Error('configureReturnValue not configured');
};
}
StubFactory.prototype.setStubMethod = function(stub) {
this.stub = stub;
};
StubFactory.prototype.setConfigureReturnValueMethod = function(configureReturnValue) {
this.configureReturnValue = configureReturnValue;
};
return StubFactory;
})();
module.exports = new StubFactory;