1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-04 15:02:09 +03:00
Files
node-redis/packages/graph/lib/commands/QUERY.spec.ts
Leibale Eidelman 1c6d74ffcb fix #2189 - add graph --compact support (#2305)
* fix #2189 - add graph --compact support

* clean code

* fix graph string param escaping

* fix "is not assignable to parameter of type 'GraphClientType'"

* fix README
2022-11-01 15:45:35 -04:00

18 lines
553 B
TypeScript

import { strict as assert } from 'assert';
import testUtils, { GLOBAL } from '../test-utils';
import { transformArguments } from './QUERY';
describe('QUERY', () => {
it('transformArguments', () => {
assert.deepEqual(
transformArguments('key', 'query'),
['GRAPH.QUERY', 'key', 'query']
);
});
testUtils.testWithClient('client.graph.query', async client => {
const { data } = await client.graph.query('key', 'RETURN 0');
assert.deepEqual(data, [[0]]);
}, GLOBAL.SERVERS.OPEN);
});