You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-03 04:01:40 +03:00
* Support new cluster commands * clean code Co-authored-by: leibale <leibale1998@gmail.com>
30 lines
806 B
TypeScript
30 lines
806 B
TypeScript
import { strict as assert } from 'assert';
|
|
import { transformArguments } from './CLUSTER_DELSLOTSRANGE';
|
|
|
|
describe('CLUSTER DELSLOTSRANGE', () => {
|
|
describe('transformArguments', () => {
|
|
it('single', () => {
|
|
assert.deepEqual(
|
|
transformArguments({
|
|
start: 0,
|
|
end: 1
|
|
}),
|
|
['CLUSTER', 'DELSLOTSRANGE', '0', '1']
|
|
);
|
|
});
|
|
|
|
it('multiple', () => {
|
|
assert.deepEqual(
|
|
transformArguments([{
|
|
start: 0,
|
|
end: 1
|
|
}, {
|
|
start: 2,
|
|
end: 3
|
|
}]),
|
|
['CLUSTER', 'DELSLOTSRANGE', '0', '1', '2', '3']
|
|
);
|
|
});
|
|
});
|
|
});
|