Skip to content

Commit

Permalink
run cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
hexcowboy committed Nov 18, 2024
1 parent f4f002f commit a0275da
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/lock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -581,8 +581,13 @@ mod tests {

redis::cmd("DEL").arg(&*key).exec_async(&mut con).await?;
assert!(
LockManager::lock_instance(&rl.lock_manager_inner.servers[0], &key, val.clone(), 10_000)
.await
LockManager::lock_instance(
&rl.lock_manager_inner.servers[0],
&key,
val.clone(),
10_000
)
.await
);

Ok(())
Expand Down Expand Up @@ -678,7 +683,10 @@ mod tests {
let key = rl.get_unique_lock_id()?;

async {
let lock_guard = rl.acquire(&key, Duration::from_millis(10_000)).await.unwrap();
let lock_guard = rl
.acquire(&key, Duration::from_millis(10_000))
.await
.unwrap();
let lock = &lock_guard.lock;
assert!(
lock.validity_time > 0,
Expand Down

0 comments on commit a0275da

Please sign in to comment.