1
0
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:
Ruben Bridgewater
2015-09-01 23:24:28 +02:00
parent ac63e852d3
commit a5938f3ade
52 changed files with 68 additions and 459 deletions

View File

@@ -1,5 +1,6 @@
var assert = require("assert");
var path = require('path');
var config = require("./lib/config");
var RedisProcess = require("./lib/redis-process");
var rp;
@@ -89,6 +90,14 @@ module.exports = {
if (version[i] < desired_version[i]) return false;
}
return true;
},
allTests: function (cb) {
['javascript', 'hiredis'].forEach(function (parser) {
cb(parser, "/tmp/redis.sock", config.configureClient(parser, "/tmp/redis.sock"));
['IPv4', 'IPv6'].forEach(function (ip) {
cb(parser, ip, config.configureClient(parser, ip));
});
});
}
}