Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
aviks authored and tanmaykm committed Jul 12, 2024
1 parent 52868df commit fd8d49d
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions test/redis_tests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -333,14 +333,15 @@ function redis_tests(conn = RedisConnection())

@testset "Scripting" begin
script = "return {KEYS[1], KEYS[2], ARGV[1], ARGV[2]}"
args = ["key1", "key2", "first", "second"]
resp = evalscript(conn, script, 2, args)
@test resp == args
keys = ["key1", "key2"]
args = ["first", "second"]
resp = evalscript(conn, script, 2, keys, args)
@test resp == vcat(keys, args)
del(conn, "key1")

script = "return redis.call('set', KEYS[1], 'bar')"
ky = "foo"
resp = evalscript(conn, script, 1, [ky])
resp = evalscript(conn, script, 1, [ky], [])
@test resp == "OK"
del(conn, ky)

Expand Down

0 comments on commit fd8d49d

Please sign in to comment.