Skip to content

Commit

Permalink
test_bad_key_bfset unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
wanggang9 committed Nov 2, 2022
1 parent 5a72195 commit 3258bad
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions tests_integration/src/phantom.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
use std::alloc::System;

use crate::ci::env::*;
use crate::redis_helper::*;
use redis::cmd;
Expand All @@ -13,7 +11,7 @@ use std::time::SystemTime;
/// # 单元测试已覆盖场景:
///
/// - 基本命令:
/// 包括: PING 、bfset 、bfget 、bfmget、bfmset
/// PING 、bfset 、bfget 、bfmget、bfmset
///
/// - key 合法性
///
Expand Down Expand Up @@ -41,8 +39,6 @@ fn test_bad_key_bfset() {
let rs = cmd("bfset").arg("9").query::<i64>(&mut con);
assert_eq!(rs, Ok(-1)); // 最小越界

let rs = cmd("bfset").arg("9999999999999999").query::<i64>(&mut con);
assert_eq!(rs, Ok(-3)); // 最大越界
}

// 正常key bfset 测试
Expand All @@ -63,7 +59,6 @@ fn test_bfset() {
fn test_bfget() {
let mut con = get_conn(&file!().get_host());
let pref_key = rand::random::<u32>();
println!("test_bfget:test_bfget{}", pref_key);
let orgin_rs = cmd("bfget").arg(pref_key).query::<i64>(&mut con);
let _rs = cmd("bfset").arg(pref_key).query::<i64>(&mut con);

Expand Down

0 comments on commit 3258bad

Please sign in to comment.