-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8f34f5c
commit 6100812
Showing
2 changed files
with
90 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import {v4} from 'uuid'; | ||
import {SetupIntegrationTest} from './integration-setup'; | ||
|
||
const {client} = SetupIntegrationTest(); | ||
|
||
describe('multiple get and set', () => { | ||
it('happy path multiple set', async () => { | ||
const key1 = v4(); | ||
const key2 = v4(); | ||
const value1 = v4(); | ||
const value2 = v4(); | ||
|
||
// Set multiple keys and values | ||
const resp = await client.mset([ | ||
[key1, value1], | ||
[key2, value2], | ||
]); | ||
expect(resp).toEqual('OK'); | ||
|
||
// Get multiple keys | ||
const getResp = await client.mget(key1, key2); | ||
expect(getResp).toEqual([value1, value2]); | ||
}); | ||
}); |