boobst
Version:
Simple Node.js Caché driver
50 lines (39 loc) • 1.11 kB
JavaScript
// Generated by CoffeeScript 1.7.1
/*
* @author Andrew D.Laptev <a.d.laptev@gmail.com>
*/
/*global describe, beforeEach, afterEach, it */
(function() {
var BoobstSocket, assert, boobst;
assert = require('assert');
boobst = require('../boobst');
BoobstSocket = boobst.BoobstSocket;
describe('xecute', function() {
var bs;
this.timeout(15000);
bs = new BoobstSocket(require('./test.config'));
beforeEach(function(done) {
return bs.connect(function(err) {
if (err) {
throw err;
}
return done();
});
});
afterEach(function(done) {
return bs.disconnect(function() {
return done();
});
});
return describe('#run hello world', function() {
return it('should properly gave us hello or disallowed', function(done) {
return bs.xecute('write "hello"', function(err, data) {
assert.equal(err, null);
assert.ok(data === 'hello' || data === 'disallowed');
return done();
});
});
});
});
}).call(this);
//# sourceMappingURL=test.xecute.map