From 65e1d6542882b794264f1e34c87ccd9a21c1a676 Mon Sep 17 00:00:00 2001 From: nyyu Date: Sun, 14 Mar 2021 14:37:27 +0100 Subject: [PATCH] Fix test --- Cargo.toml | 24 ++++++++++++------------ src/kb_data_source.rs | 4 ++-- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index ffec650..988916d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,26 +1,26 @@ [package] -name = "cggitem_sets" -version = "0.1.0" authors = ["nyyu "] edition = "2018" +name = "cggitem_sets" +version = "0.1.0" [dependencies] +indexmap = {version = "1.6", features = ["serde-1"]} +lazy_static = "1.4" log = "0.4" -simple_logger = "1.11" +regex = "1.4" +select = "0.5" serde = "1.0" serde_derive = "1.0" -serde_json = { version = "1.0", features = ["preserve_order"] } -select = "0.5" -regex = "1.4" -lazy_static = "1.4" -indexmap = { version = "1.6", features = ["serde-1"] } -ureq = { version = "2.0", features = ["json", "charset"] } +serde_json = {version = "1.0", features = ["preserve_order"]} +simple_logger = "1.11" +ureq = {version = "2.0", features = ["json", "charset"]} [target.'cfg(windows)'.dependencies] winreg = "0.8" [profile.release] -opt-level = 'z' -lto = true codegen-units = 1 -panic = 'abort' \ No newline at end of file +lto = true +opt-level = 'z' +panic = 'abort' diff --git a/src/kb_data_source.rs b/src/kb_data_source.rs index dc4fa00..73819b2 100644 --- a/src/kb_data_source.rs +++ b/src/kb_data_source.rs @@ -395,8 +395,8 @@ mod tests { assert!(result.is_some()); match result { Some(value) => { - assert!(value.0.len() > 0); - assert!(value.1 > 0.); + assert!(!value.0.is_empty()); + assert!(value.1.win_rate > 0.); } None => assert!(false), }