1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-04 15:02:09 +03:00

increase pushGeoCountArgument test coverage

This commit is contained in:
leibale
2021-11-27 23:51:15 -05:00
parent f2d46c8787
commit bc1bf7e7b1

View File

@@ -320,21 +320,32 @@ describe('Generic Transformers', () => {
);
});
it('with COUNT', () => {
assert.deepEqual(
pushGeoCountArgument([], 1),
['COUNT', '1']
);
});
describe('with COUNT', () => {
it('number', () => {
assert.deepEqual(
pushGeoCountArgument([], 1),
['COUNT', '1']
);
});
it('with ANY', () => {
assert.deepEqual(
pushGeoCountArgument([], {
value: 1,
ANY: true
}),
['COUNT', '1', 'ANY']
);
describe('object', () => {
it('value', () => {
assert.deepEqual(
pushGeoCountArgument([], { value: 1 }),
['COUNT', '1']
);
});
it('value, ANY', () => {
assert.deepEqual(
pushGeoCountArgument([], {
value: 1,
ANY: true
}),
['COUNT', '1', 'ANY']
);
});
});
});
});