You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-06 02:15:48 +03:00
Increase the coverage
This commit is contained in:
@@ -23,7 +23,9 @@ describe("The 'blpop' method", function () {
|
||||
|
||||
it('pops value immediately if list contains values', function (done) {
|
||||
bclient = redis.createClient.apply(redis.createClient, args);
|
||||
redis.debug_mode = true;
|
||||
client.rpush("blocking list", "initial value", helper.isNumber(1));
|
||||
redis.debug_mode = false;
|
||||
bclient.blpop("blocking list", 0, function (err, value) {
|
||||
assert.strictEqual(value[0], "blocking list");
|
||||
assert.strictEqual(value[1], "initial value");
|
||||
|
@@ -64,6 +64,7 @@ describe("The 'get' method", function () {
|
||||
});
|
||||
|
||||
it("gets the value correctly", function (done) {
|
||||
client.GET(key, redis.print); // Use the utility function to print the result
|
||||
client.GET(key, function (err, res) {
|
||||
helper.isString(value)(err, res);
|
||||
done(err);
|
||||
|
@@ -34,6 +34,7 @@ describe("The 'getset' method", function () {
|
||||
});
|
||||
|
||||
it("reports an error", function (done) {
|
||||
client.GET(key, redis.print); // Use the utility function to print the error
|
||||
client.get(key, function (err, res) {
|
||||
assert.equal(err.message, 'Redis connection gone from end event.');
|
||||
done();
|
||||
|
Reference in New Issue
Block a user