Skip to content

Commit

Permalink
redis - adding in testing on delete when not using redis sets (#920)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredwray authored Sep 17, 2023
1 parent cbe367c commit 103faa7
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions packages/redis/test/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,3 +169,17 @@ test.serial('when passing in ioredis set the options.useRedisSets', t => {

t.is(keyv.opts.useRedisSets, false);
});

test.serial('del should work when not using useRedisSets', async t => {
const options = {useRedisSets: false};
const redis = new Redis(redisURI);
const keyv = new KeyvRedis(redis, options);

await keyv.set('fooDel1', 'barDel1');

await keyv.delete('fooDel1');

const value = await keyv.get('fooDel1');

t.is(value, undefined);
});

0 comments on commit 103faa7

Please sign in to comment.