Skip to content

Commit 2d22d96

Browse files
committed
test: update runtime test helpers
1 parent 65a57bf commit 2d22d96

3 files changed

Lines changed: 7 additions & 15 deletions

File tree

src/execution/dml/copy_from_file.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,8 +177,8 @@ mod tests {
177177
};
178178

179179
let mut transaction = db.storage.transaction()?;
180-
let mut executor = crate::execution::execute_mut(
181-
CopyFromFile::from(op),
180+
let mut executor = crate::execution::execute_input_mut::<_, CopyFromFile>(
181+
op,
182182
(
183183
db.state.table_cache(),
184184
db.state.view_cache(),

src/execution/dml/copy_to_file.rs

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -169,19 +169,10 @@ mod tests {
169169
.table(db.state.table_cache(), "t1".to_string().into())?
170170
.unwrap();
171171

172-
let executor = CopyToFile {
173-
op: op.clone(),
174-
input_plan: TableScanOperator::build(
175-
"t1".to_string().into(),
176-
table,
177-
true,
178-
&plan_arena,
179-
)?,
180-
column_names: Default::default(),
181-
input: None,
182-
};
183-
let mut executor = crate::execution::execute_mut(
184-
executor,
172+
let input_plan =
173+
TableScanOperator::build("t1".to_string().into(), table, true, &plan_arena)?;
174+
let mut executor = crate::execution::execute_input_mut::<_, CopyToFile>(
175+
(op.clone(), input_plan),
185176
(
186177
db.state.table_cache(),
187178
db.state.view_cache(),

src/types/evaluator/utf8.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,7 @@ fn next_char_at(input: &str, index: usize) -> Option<(char, usize)> {
347347
#[cfg(all(test, not(target_arch = "wasm32")))]
348348
mod test {
349349
use super::*;
350+
use chrono::{Datelike, Timelike};
350351

351352
fn utf8(value: &str) -> DataValue {
352353
DataValue::Utf8 {

0 commit comments

Comments
 (0)