Skip to content

Commit 12e93a4

Browse files
authored
test: One liner to skip read_table_version_hdfs (delta-io#1428)
## What changes are proposed in this pull request? This PR adds an \`#[ignore]\` attribute to the \`read_table_version_hdfs\` test to skip it when the Maven executable is not available on the system. **Problem:** The HDFS integration test was failing in environments where Maven is not installed: ``` cargo test --all-features ``` ``` thread 'read_table_version_hdfs' panicked at /Users/sanuj.basu/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/ hdfs-native-0.12.3/src/minidfs.rs:59:37: Failed to find mvn executable: CannotFindBinaryPath ``` **Solution:** Added the \`#[ignore = \"Skipping HDFS integration test\"]\` attribute to the \`read_table_version_hdfs\` test function. This allows the test to be skipped by default while still being available to run explicitly when needed. ## How was this change tested? Verified that the test is properly skipped: ``` running 1 test test read_table_version_hdfs ... ignored, Skipping HDFS integration test test result: ok. 0 passed; 0 failed; 1 ignored; 0 measured; 0 filtered out ``` The test can still be run explicitly with: ```bash cargo test --features integration-test --test hdfs -- --include-ignored ```
1 parent 70143ca commit 12e93a4

2 files changed

Lines changed: 2 additions & 9 deletions

File tree

README.md

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -153,15 +153,7 @@ Some design principles which should be considered:
153153
- If using `emacs`, both [eglot](https://github.com/joaotavora/eglot) and
154154
[lsp-mode](https://github.com/emacs-lsp/lsp-mode) provide excellent integration with
155155
`rust-analyzer`. [rustic](https://github.com/brotzeit/rustic) is a nice mode as well.
156-
- When also developing in VS Code it's sometimes convenient to configure rust-analyzer in
157-
`.vscode/settings.json`.
158-
159-
```json
160-
{
161-
"editor.formatOnSave": true,
162-
"rust-analyzer.cargo.features": ["default-engine"]
163-
}
164-
```
156+
- When also developing in VS Code it's convenient to add rust-analyzer to your workspace.
165157

166158
- The crate's documentation can be easily reviewed with: `cargo docs --open`
167159
- Code coverage is available on codecov via [cargo-llvm-cov]. See their docs for instructions to install/run locally.

kernel/tests/hdfs.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ async fn write_local_path_to_hdfs(
5252
}
5353

5454
#[tokio::test]
55+
#[ignore = "Skipping HDFS integration test"]
5556
async fn read_table_version_hdfs() -> Result<(), Box<dyn std::error::Error>> {
5657
let minidfs = MiniDfs::with_features(&HashSet::new());
5758
let hdfs_client = Client::default();

0 commit comments

Comments
 (0)