ioredis-mock icon indicating copy to clipboard operation
ioredis-mock copied to clipboard

nodes is not a function error (redis cluster)

Open akhan5 opened this issue 2 years ago • 1 comments

@stipsan I tried to use the ioredis-mock library in our project with the following line of code to mock redis cluster.

jest.mock("ioredis", () => jest.requireActual("ioredis-mock"));

but I am getting (nodes is not a function) error in test cases.

Here is a reference to nodes() command in ioredis library. https://github.com/luin/ioredis#running-commands-to-multiple-nodes

akhan5 avatar Jul 26 '22 15:07 akhan5

Hi, Clusters are indeed not fully supported. PRs welcome ☺️

stipsan avatar Jul 30 '22 00:07 stipsan