From f5c25b6fff5ab97b1016239034605256bfcd54a4 Mon Sep 17 00:00:00 2001 From: Will Jones Date: Mon, 23 Sep 2024 07:33:47 -0700 Subject: [PATCH] ci: run clippy on tests (#1659) --- .github/workflows/rust.yml | 3 +-- rust/lancedb/src/table.rs | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 83a4eacb..c4200df8 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -30,7 +30,6 @@ jobs: defaults: run: shell: bash - working-directory: rust env: # Need up-to-date compilers for kernels CC: gcc-12 @@ -50,7 +49,7 @@ jobs: - name: Run format run: cargo fmt --all -- --check - name: Run clippy - run: cargo clippy --all --all-features -- -D warnings + run: cargo clippy --workspace --tests --all-features -- -D warnings linux: timeout-minutes: 30 # To build all features, we need more disk space than is available diff --git a/rust/lancedb/src/table.rs b/rust/lancedb/src/table.rs index 5e753e9f..86fd1d1b 100644 --- a/rust/lancedb/src/table.rs +++ b/rust/lancedb/src/table.rs @@ -3234,7 +3234,7 @@ mod tests { let values_builder = StringBuilder::new(); let mut builder = ListBuilder::new(values_builder); for i in 0..120 { - builder.values().append_value(TAGS[i % 3].to_string()); + builder.values().append_value(TAGS[i % 3]); if i % 3 == 0 { builder.append(true) }