@aantonov/redis-mock
v0.0.16
Published
Redis mock for tests
Downloads
81
Readme
#redis-mock
Installation
$ [sudo] npm install --save @aantonov/redis-mock
Usage
var assert = require('assert');
var redis_client = require('@aantonov/redis-mock');
it ('Should save string value', (done) => {
var test_key = 'test_key',
test_val = 'test_val';
redis_client.set(test_key, test_val, (err) => {
if (err) return done(err);
assert.equal(redis.store[test_key], test_val);
done();
});
});