You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-06 02:15:48 +03:00
Refactor the test suite and remove duplicated code
This commit is contained in:
@@ -7,8 +7,7 @@ var uuid = require('uuid');
|
||||
|
||||
describe("The 'flushdb' method", function () {
|
||||
|
||||
function allTests(parser, ip) {
|
||||
var args = config.configureClient(parser, ip);
|
||||
helper.allTests(function(parser, ip, args) {
|
||||
|
||||
describe("using " + parser + " and " + ip, function () {
|
||||
var key, key2;
|
||||
@@ -104,12 +103,5 @@ describe("The 'flushdb' method", function () {
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
['javascript', 'hiredis'].forEach(function (parser) {
|
||||
allTests(parser, "/tmp/redis.sock");
|
||||
['IPv4', 'IPv6'].forEach(function (ip) {
|
||||
allTests(parser, ip);
|
||||
})
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user