Skip to content

Commit

Permalink
fix: import JoinTestType without triggering unused_qualifications lint (
Browse files Browse the repository at this point in the history
#13170)

* fix: import JoinTestType without triggering unused_qualifications lint

* fix: remove use statement instead of removing qualifications
  • Loading branch information
smarticen authored Oct 30, 2024
1 parent 68bf7ad commit 8c6bb39
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions datafusion/core/tests/fuzz_cases/join_fuzz.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ use datafusion::physical_plan::joins::{
};
use datafusion::physical_plan::memory::MemoryExec;

use crate::fuzz_cases::join_fuzz::JoinTestType::NljHj;
use datafusion::prelude::{SessionConfig, SessionContext};
use test_utils::stagger_batch_with_seed;

Expand Down Expand Up @@ -90,7 +89,6 @@ fn col_lt_col_filter(schema1: Arc<Schema>, schema2: Arc<Schema>) -> JoinFilter {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_inner_join_1k_filtered() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -103,7 +101,6 @@ async fn test_inner_join_1k_filtered() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_inner_join_1k() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -116,7 +113,6 @@ async fn test_inner_join_1k() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_left_join_1k() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -129,7 +125,6 @@ async fn test_left_join_1k() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_left_join_1k_filtered() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -142,7 +137,6 @@ async fn test_left_join_1k_filtered() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_right_join_1k() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -155,7 +149,6 @@ async fn test_right_join_1k() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_right_join_1k_filtered() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -168,7 +161,6 @@ async fn test_right_join_1k_filtered() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_full_join_1k() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -181,7 +173,6 @@ async fn test_full_join_1k() {
}

#[tokio::test]
#[allow(unused_qualifications)]
// flaky for HjSmj case
// https://github.com/apache/datafusion/issues/12359
async fn test_full_join_1k_filtered() {
Expand All @@ -196,7 +187,6 @@ async fn test_full_join_1k_filtered() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_semi_join_1k() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -209,7 +199,6 @@ async fn test_semi_join_1k() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_semi_join_1k_filtered() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -222,7 +211,6 @@ async fn test_semi_join_1k_filtered() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_anti_join_1k() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
Expand All @@ -235,15 +223,14 @@ async fn test_anti_join_1k() {
}

#[tokio::test]
#[allow(unused_qualifications)]
async fn test_anti_join_1k_filtered() {
JoinFuzzTestCase::new(
make_staggered_batches(1000),
make_staggered_batches(1000),
JoinType::LeftAnti,
Some(Box::new(col_lt_col_filter)),
)
.run_test(&[JoinTestType::HjSmj, NljHj], false)
.run_test(&[JoinTestType::HjSmj, JoinTestType::NljHj], false)
.await
}

Expand Down Expand Up @@ -461,7 +448,6 @@ impl JoinFuzzTestCase {
/// `join_tests` - identifies what join types to test
/// if `debug` flag is set the test will save randomly generated inputs and outputs to user folders,
/// so it is easy to debug a test on top of the failed data
#[allow(unused_qualifications)]
async fn run_test(&self, join_tests: &[JoinTestType], debug: bool) {
for batch_size in self.batch_sizes {
let session_config = SessionConfig::new().with_batch_size(*batch_size);
Expand Down

0 comments on commit 8c6bb39

Please sign in to comment.