1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-07 13:22:56 +03:00

some more commands

This commit is contained in:
Leibale
2023-04-30 10:33:05 -04:00
parent 53b9397a78
commit 88333c01de
25 changed files with 458 additions and 491 deletions

View File

@@ -1,27 +1,23 @@
import { strict as assert } from 'assert';
import testUtils, { GLOBAL } from '../test-utils';
import { transformArguments } from './LRANGE';
import LRANGE from './LRANGE';
describe('LRANGE', () => {
it('transformArguments', () => {
assert.deepEqual(
transformArguments('key', 0, -1),
['LRANGE', 'key', '0', '-1']
);
});
it('transformArguments', () => {
assert.deepEqual(
LRANGE.transformArguments('key', 0, -1),
['LRANGE', 'key', '0', '-1']
);
});
testUtils.testWithClient('client.lRange', async client => {
assert.deepEqual(
await client.lRange('key', 0, -1),
[]
);
}, GLOBAL.SERVERS.OPEN);
testUtils.testWithCluster('cluster.lRange', async cluster => {
assert.deepEqual(
await cluster.lRange('key', 0, -1),
[]
);
}, GLOBAL.CLUSTERS.OPEN);
testUtils.testAll('lRange', async client => {
assert.deepEqual(
await client.lRange('key', 0, -1),
[]
);
}, {
client: GLOBAL.SERVERS.OPEN,
cluster: GLOBAL.CLUSTERS.OPEN
});
});