node-postgres/test/unit/client/notification-tests.js

10 lines
269 B
JavaScript
Raw Normal View History

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