Skip to content

Commit 89a9c9d

Browse files
Feat: Add an option for fast tests by gating slow tests to extended_tests feature (#19237)
## Which issue does this PR close? Closes #19228 ## Rationale for this change This PR gates all fuzz tests behind the ```extended_tests``` feature flag, allowing developers to run a fast test suite (ideally under 1 minute) during development while still being able to run the full test suite in CI or when needed. ## What changes are included in this PR? Added #[cfg(feature = "extended_tests")] to all fuzz test modules in mod.rs. This includes the following modules: - aggregate_fuzz - distinct_count_string_fuzz - join_fuzz - merge_fuzz - sort_fuzz - sort_query_fuzz - topk_filter_pushdown - aggregation_fuzzer - equivalence - pruning - limit_fuzz - sort_preserving_repartition_fuzz - window_fuzz - Utility modules ## Are these changes tested? Without the extended_tests feature: ```cargo test --package datafusion --test fuzz -- --list``` This shows 0 tests. With the extended_tests feature: ```cargo test --package datafusion --test fuzz --features extended_tests -- --list``` This shows all ~100+ fuzz tests. ## Are there any user-facing changes? Yes. Users can now run: Fast test suite (default): ```cargo test``` or ```cargo nextest run``` Full test suite with fuzz tests: ```cargo test --features extended_tests``` or ```cargo nextest run --features extended_tests```
1 parent 39a1f75 commit 89a9c9d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

datafusion/core/tests/fuzz.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,10 @@
1515
// specific language governing permissions and limitations
1616
// under the License.
1717

18-
/// Run all tests that are found in the `fuzz_cases` directory
18+
/// Run all tests that are found in the `fuzz_cases` directory.
19+
/// Fuzz tests are slow and gated behind the `extended_tests` feature.
20+
/// Run with: cargo test --features extended_tests
21+
#[cfg(feature = "extended_tests")]
1922
mod fuzz_cases;
2023

2124
#[cfg(test)]

0 commit comments

Comments
 (0)