You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-09-02 22:41:17 +03:00
add tests
This commit is contained in:
19
lib/commands/HINCRBYFLOAT.spec.ts
Normal file
19
lib/commands/HINCRBYFLOAT.spec.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
import { strict as assert } from 'assert';
|
||||
import { TestRedisServers, itWithClient } from '../test-utils';
|
||||
import { transformArguments } from './HINCRBYFLOAT';
|
||||
|
||||
describe('HINCRBYFLOAT', () => {
|
||||
it('transformArguments', () => {
|
||||
assert.deepEqual(
|
||||
transformArguments('key', 'field', 1.5),
|
||||
['HINCRBYFLOAT', 'key', 'field', '1.5']
|
||||
);
|
||||
});
|
||||
|
||||
itWithClient(TestRedisServers.OPEN, 'client.hIncrByFloat', async client => {
|
||||
assert.equal(
|
||||
await client.hIncrByFloat('key', 'field', 1.5),
|
||||
'1.5'
|
||||
);
|
||||
});
|
||||
});
|
Reference in New Issue
Block a user