diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d995051b7..737ab20dd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -118,7 +118,7 @@ jobs: RUSTFLAGS: -D warnings with: command: check - args: --all --bins --examples --tests --features repl + args: --all --bins --examples --tests --features repl --benches - name: tests uses: actions-rs/cargo@v1 diff --git a/benches/contacts.rs b/benches/contacts.rs index 4478c8d84..5e6010233 100644 --- a/benches/contacts.rs +++ b/benches/contacts.rs @@ -8,9 +8,7 @@ async fn address_book_benchmark(n: u32, read_count: u32) { let dir = tempdir().unwrap(); let dbfile = dir.path().join("db.sqlite"); let id = 100; - let context = Context::new("FakeOS".into(), dbfile.into(), id) - .await - .unwrap(); + let context = Context::new(dbfile.into(), id).await.unwrap(); let book = (0..n) .map(|i| format!("Name {}\naddr{}@example.org\n", i, i)) diff --git a/benches/create_account.rs b/benches/create_account.rs index 949906578..531d8ead8 100644 --- a/benches/create_account.rs +++ b/benches/create_account.rs @@ -8,7 +8,7 @@ async fn create_accounts(n: u32) { let dir = tempdir().unwrap(); let p: PathBuf = dir.path().join("accounts").into(); - let accounts = Accounts::new("my_os".into(), p.clone()).await.unwrap(); + let mut accounts = Accounts::new(p.clone()).await.unwrap(); for expected_id in 2..n { let id = accounts.add_account().await.unwrap(); diff --git a/benches/search_msgs.rs b/benches/search_msgs.rs index efd19ed6f..8c1b8b770 100644 --- a/benches/search_msgs.rs +++ b/benches/search_msgs.rs @@ -6,9 +6,7 @@ use std::path::Path; async fn search_benchmark(path: impl AsRef) { let dbfile = path.as_ref(); let id = 100; - let context = Context::new("FakeOS".into(), dbfile.into(), id) - .await - .unwrap(); + let context = Context::new(dbfile.into(), id).await.unwrap(); for _ in 0..10u32 { context.search_msgs(None, "hello").await.unwrap();