Skip to content

Commit

Permalink
using TestConnection API
Browse files Browse the repository at this point in the history
  • Loading branch information
ephraimfeldblum committed Nov 4, 2024
1 parent 56cf136 commit fc51c7e
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions tests/integration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -278,11 +278,7 @@ fn test_get_current_user() -> Result<()> {
#[test]
#[cfg(feature = "min-redis-compatibility-version-7-4")]
fn test_set_acl_categories() -> Result<()> {
let port: u16 = 6490;
let _guards = vec![start_redis_server_with_module("acl", port)
.with_context(|| "failed to start redis server")?];
let mut con =
get_redis_connection(port).with_context(|| "failed to connect to redis server")?;
let mut con = TestConnection::new("acl");

let res: Vec<String> = redis::cmd("ACL").arg("CAT").query(&mut con)?;
assert!(res.contains(&"acl".to_owned()));
Expand All @@ -293,11 +289,7 @@ fn test_set_acl_categories() -> Result<()> {
#[test]
#[cfg(feature = "min-redis-compatibility-version-8-0")]
fn test_set_acl_categories_commands() -> Result<()> {
let port: u16 = 6490;
let _guards = vec![start_redis_server_with_module("acl", port)
.with_context(|| "failed to start redis server")?];
let mut con =
get_redis_connection(port).with_context(|| "failed to connect to redis server")?;
let mut con = TestConnection::new("acl");

let res: Vec<String> = redis::cmd("ACL").arg("CAT").arg("acl").query(&mut con)?;
assert!(
Expand Down

0 comments on commit fc51c7e

Please sign in to comment.