Last active
August 29, 2015 14:17
-
-
Save othiym23/8442dfaed6289dd94f09 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var test = require("tape") | |
test("redis-url", function (t) { | |
t.plan(2); | |
var redis = require('..').createClient() | |
var redis2 = require('..').createClient('redis://localhost:6379') | |
redis.set('foo', 'bar'); | |
redis.get('foo', function(err, res) { | |
if (err) throw err | |
t.equal(res, 'bar', "foo should equal bar") | |
redis.quit() | |
}) | |
redis2.set('food', 'bar'); | |
redis2.get('food', function(err, res) { | |
if (err) throw err | |
t.equal(res, 'bar') | |
redis2.quit() | |
}) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment