You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-07 13:22:56 +03:00
wip
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
import { strict as assert } from 'assert';
|
import { strict as assert } from 'assert';
|
||||||
import testUtils, { GLOBAL, MIN_BLOCKING_TIME } from '../test-utils';
|
import testUtils, { GLOBAL, BLOCKING_MIN_VALUE } from '../test-utils';
|
||||||
import BLMOVE from './BLMOVE';
|
import BLMOVE from './BLMOVE';
|
||||||
|
|
||||||
describe('BLMOVE', () => {
|
describe('BLMOVE', () => {
|
||||||
@@ -14,7 +14,7 @@ describe('BLMOVE', () => {
|
|||||||
|
|
||||||
testUtils.testAll('blMove - null', async client => {
|
testUtils.testAll('blMove - null', async client => {
|
||||||
assert.equal(
|
assert.equal(
|
||||||
await client.blMove('{tag}source', '{tag}destination', 'LEFT', 'RIGHT', MIN_BLOCKING_TIME),
|
await client.blMove('{tag}source', '{tag}destination', 'LEFT', 'RIGHT', BLOCKING_MIN_VALUE),
|
||||||
null
|
null
|
||||||
);
|
);
|
||||||
}, {
|
}, {
|
||||||
@@ -25,7 +25,7 @@ describe('BLMOVE', () => {
|
|||||||
testUtils.testAll('blMove - with member', async client => {
|
testUtils.testAll('blMove - with member', async client => {
|
||||||
const [, reply] = await Promise.all([
|
const [, reply] = await Promise.all([
|
||||||
client.lPush('{tag}source', 'element'),
|
client.lPush('{tag}source', 'element'),
|
||||||
client.blMove('{tag}source', '{tag}destination', 'LEFT', 'RIGHT', MIN_BLOCKING_TIME)
|
client.blMove('{tag}source', '{tag}destination', 'LEFT', 'RIGHT', BLOCKING_MIN_VALUE)
|
||||||
]);
|
]);
|
||||||
assert.equal(reply, 'element');
|
assert.equal(reply, 'element');
|
||||||
}, {
|
}, {
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
import { strict as assert } from 'assert';
|
import { strict as assert } from 'assert';
|
||||||
import testUtils, { GLOBAL, MIN_BLOCKING_TIME } from '../test-utils';
|
import testUtils, { GLOBAL, BLOCKING_MIN_VALUE } from '../test-utils';
|
||||||
import BLMPOP from './BLMPOP';
|
import BLMPOP from './BLMPOP';
|
||||||
|
|
||||||
describe('BLMPOP', () => {
|
describe('BLMPOP', () => {
|
||||||
@@ -25,7 +25,7 @@ describe('BLMPOP', () => {
|
|||||||
|
|
||||||
testUtils.testAll('blmPop - null', async client => {
|
testUtils.testAll('blmPop - null', async client => {
|
||||||
assert.equal(
|
assert.equal(
|
||||||
await client.blmPop(MIN_BLOCKING_TIME, 'key', 'RIGHT'),
|
await client.blmPop(BLOCKING_MIN_VALUE, 'key', 'RIGHT'),
|
||||||
null
|
null
|
||||||
);
|
);
|
||||||
}, {
|
}, {
|
||||||
@@ -36,7 +36,7 @@ describe('BLMPOP', () => {
|
|||||||
testUtils.testAll('blmPop - with member', async client => {
|
testUtils.testAll('blmPop - with member', async client => {
|
||||||
const [, reply] = await Promise.all([
|
const [, reply] = await Promise.all([
|
||||||
client.lPush('key', 'element'),
|
client.lPush('key', 'element'),
|
||||||
client.blmPop(MIN_BLOCKING_TIME, 'key', 'RIGHT')
|
client.blmPop(BLOCKING_MIN_VALUE, 'key', 'RIGHT')
|
||||||
]);
|
]);
|
||||||
assert.deepEqual(reply, [
|
assert.deepEqual(reply, [
|
||||||
'key',
|
'key',
|
||||||
|
Reference in New Issue
Block a user