Skip to content

Commit

Permalink
Moved RPOP to URP.
Browse files Browse the repository at this point in the history
  • Loading branch information
rgeoghegan committed May 2, 2011
1 parent 2082f03 commit fc6f70f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/redis.ml
Expand Up @@ -250,7 +250,7 @@ let lpop key connection =

let rpop key connection =
(* RPOP *)
match send_and_receive_command_safely ("RPOP " ^ key) connection with
match send_multibulk_and_receive_command_safely ["RPOP"; key] connection with
Bulk(x) -> x |
_ -> failwith "Did not recognize what I got back";;

Expand Down
7 changes: 4 additions & 3 deletions tests/test_redis_lists.ml
Expand Up @@ -178,11 +178,12 @@ let test_rpop () =
use_test_script
((read_lines_from_list
["LPUSH"; "rory"; "cool"])
@ [WriteThisLine(":1")]
@ (read_lines_from_list
["RPOP"; "rory"])
@ [
WriteThisLine(":1");
ReadThisLine("RPOP rory");
WriteThisLine("$4");
WriteThisLine("cool");
WriteThisLine("cool")
])
test_func;;

Expand Down

0 comments on commit fc6f70f

Please sign in to comment.