kumarUjjawal commented on code in PR #25256: URL: https://github.com/apache/datafusion/pull/25256#discussion_r3999223218
########## xtask/README.md: ########## @@ -40,3 +40,62 @@ For example, `cargo xtask ci step test workspace` runs DataFusion's default CI t The goal is to keep local development and GitHub CI runs in sync. Each CI step command is defined once in this in-repository Rust binary and is invoked the same way locally and in GitHub Actions. Tracking issue: https://github.com/apache/datafusion/issues/24487 + +### Extended test suites + +The [extended tests] are long-running suites that run in the merge queue, on +pushes to release branches, and on manual dispatch. They do not run on ordinary +pull request updates. Each job in [`extended.yml`] runs one of these commands: + +| GitHub Actions job | Command | +| ---------------------------------------------- | ------------------------------------------ | +| `cargo test 'extended_tests' (amd64)` | `cargo xtask ci step test extended` | +| `cargo test hash collisions (amd64)` | `cargo xtask ci step test hash-collisions` | +| `Run sqllogictests with the sqlite test suite` | `cargo xtask ci step test sqlite` | + +Append `--explain` to print the `cargo test` invocation, its working directory, +and the environment variables the command sets, without running the suite: + +```shell +cargo xtask ci step test extended --explain +cargo xtask ci step test hash-collisions --explain +cargo xtask ci step test sqlite --explain +``` + +Each command sets only the environment variables that its test suite needs. +Everything else is inherited from the calling shell: + +- `extended` sets `RUST_BACKTRACE=1` and `DATAFUSION_SPILL_POOL_FUZZ_ITERATIONS=1000`. + The second variable runs more random spill pool fuzzer scenarios than the + default test suite does. +- `hash-collisions` runs from the `datafusion` directory and sets + `RUST_BACKTRACE=1`, which matches the CI builder setup for that job. +- `sqlite` sets no variables. Its CI job deliberately skips the builder setup + because backtraces make this suite much slower. A `RUST_BACKTRACE` value + inherited from your shell therefore makes a local run differ from CI. + +#### Prerequisites + +- The Rust toolchain from `rust-toolchain.toml` and the Protobuf compiler + (`protoc`). See the [development environment] guide. +- The test data submodules. The `sqlite` suite reads + `datafusion-testing/data/sqlite`: + + ```shell + git submodule update --init --recursive + ``` + +- Time and disk space. These suites build most of the workspace with test + features enabled, and the `sqlite` suite runs several million queries. + +#### What a test command does not do + +A test command reproduces one `cargo test` invocation from a CI job. It is not +the complete job. The GitHub Actions workflow still installs the toolchain, +configures build flags, caching, and network settings, verifies that the +working tree is clean, and runs `cargo clean`. The commands never run cleanup +and never call the GitHub API, so they are safe to run in a local checkout. + +[extended tests]: https://github.com/apache/datafusion/blob/main/docs/source/contributor-guide/testing.md#extended-tests +[`extended.yml`]: https://github.com/apache/datafusion/blob/main/.github/workflows/extended.yml +[development environment]: https://github.com/apache/datafusion/blob/main/docs/source/contributor-guide/development_environment.md Review Comment: Thank you sounds good! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
