Skip to content

Commit 864b753

Browse files
committed
move test-related stuffs to test_utils
1 parent 7f947d3 commit 864b753

File tree

10 files changed

+575
-591
lines changed

10 files changed

+575
-591
lines changed

optd-cost-model/src/cost/agg.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,12 @@ mod tests {
7171

7272
use crate::{
7373
common::predicates::constant_pred::ConstantType,
74-
cost_model::tests::{
74+
stats::{utilities::simple_map::SimpleMap, MostCommonValues, DEFAULT_NUM_DISTINCT},
75+
test_utils::tests::{
7576
attr_index, create_mock_cost_model_with_attr_types, empty_list, list,
7677
TestPerAttributeStats, TEST_ATTR1_BASE_INDEX, TEST_ATTR2_BASE_INDEX,
7778
TEST_ATTR3_BASE_INDEX, TEST_GROUP1_ID, TEST_TABLE1_ID,
7879
},
79-
stats::{utilities::simple_map::SimpleMap, MostCommonValues, DEFAULT_NUM_DISTINCT},
8080
EstimatedStatistic,
8181
};
8282

optd-cost-model/src/cost/filter/core.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,8 @@ mod tests {
101101
types::TableId,
102102
values::Value,
103103
},
104-
cost_model::tests::*,
105104
stats::{utilities::simple_map::SimpleMap, Distribution, MostCommonValues, DEFAULT_EQ_SEL},
105+
test_utils::tests::*,
106106
};
107107
use arrow_schema::DataType;
108108

optd-cost-model/src/cost/filter/in_list.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@ mod tests {
8484

8585
use crate::{
8686
common::values::Value,
87-
cost_model::tests::*,
8887
stats::{utilities::simple_map::SimpleMap, MostCommonValues},
88+
test_utils::tests::*,
8989
};
9090

9191
#[tokio::test]

optd-cost-model/src/cost/filter/like.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,11 +114,11 @@ mod tests {
114114

115115
use crate::{
116116
common::values::Value,
117-
cost_model::tests::*,
118117
stats::{
119118
utilities::{counter::Counter, simple_map::SimpleMap},
120119
MostCommonValues, FIXED_CHAR_SEL_FACTOR, FULL_WILDCARD_SEL_FACTOR,
121120
},
121+
test_utils::tests::*,
122122
};
123123

124124
#[tokio::test]

optd-cost-model/src/cost/join/core.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -415,16 +415,16 @@ mod tests {
415415
properties::{attr_ref, Attribute},
416416
values::Value,
417417
},
418-
cost_model::tests::{
418+
stats::DEFAULT_EQ_SEL,
419+
test_utils::tests::MemoGroupInfo,
420+
test_utils::tests::{
419421
attr_index, bin_op, cnst, create_four_table_mock_cost_model, create_mock_cost_model,
420422
create_three_table_mock_cost_model, create_two_table_mock_cost_model,
421423
create_two_table_mock_cost_model_custom_row_cnts, empty_per_attr_stats, log_op,
422424
per_attr_stats_with_dist_and_ndistinct, per_attr_stats_with_ndistinct,
423425
TestOptCostModelMock, TEST_ATTR1_NAME, TEST_ATTR2_NAME, TEST_TABLE1_ID, TEST_TABLE2_ID,
424426
TEST_TABLE3_ID, TEST_TABLE4_ID,
425427
},
426-
memo_ext::tests::MemoGroupInfo,
427-
stats::DEFAULT_EQ_SEL,
428428
};
429429

430430
use super::*;

0 commit comments

Comments
 (0)