2011-03-04 12:55:06 +08:00
|
|
|
var helper = require(__dirname + "/test-helper");
|
|
|
|
test('passes connection notification', function() {
|
|
|
|
var client = new Client();
|
2011-03-04 13:20:47 +08:00
|
|
|
assert.emits(client, 'notification', function(msg) {
|
2011-03-04 12:55:06 +08:00
|
|
|
assert.equal(msg, "HAY!!");
|
|
|
|
})
|
2011-03-04 13:20:47 +08:00
|
|
|
client.connection.emit('notification', "HAY!!");
|
2011-03-04 12:55:06 +08:00
|
|
|
})
|
|
|
|
|