Skip to content

Commit d0d2424

Browse files
committed
Hack on it until the tests compile
1 parent 96867cc commit d0d2424

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

kernel/src/engine/default/json.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ mod tests {
447447
&self,
448448
prefix: Option<&Path>,
449449
offset: &Path,
450-
) -> BoxStream<'_, Result<ObjectMeta>> {
450+
) -> BoxStream<'static, Result<ObjectMeta>> {
451451
self.inner.list_with_offset(prefix, offset)
452452
}
453453

@@ -532,7 +532,7 @@ mod tests {
532532
let files = &[FileMeta {
533533
location: url.clone(),
534534
last_modified: meta.last_modified.timestamp_millis(),
535-
size: meta.size,
535+
size: meta.size as usize,
536536
}];
537537

538538
let handler = DefaultJsonHandler::new(store, Arc::new(TokioBackgroundExecutor::new()));
@@ -681,7 +681,7 @@ mod tests {
681681
FileMeta {
682682
location: url,
683683
last_modified: meta.last_modified.timestamp_millis(),
684-
size: meta.size,
684+
size: meta.size as usize,
685685
}
686686
}
687687
})

kernel/src/engine/default/parquet.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -395,7 +395,8 @@ mod tests {
395395
let location = Path::from(url.path());
396396
let meta = store.head(&location).await.unwrap();
397397

398-
let reader = ParquetObjectReader::new(store.clone(), meta.clone());
398+
let reader = ParquetObjectReader::new(store.clone(), meta.location)
399+
.with_file_size(meta.size);
399400
let physical_schema = ParquetRecordBatchStreamBuilder::new(reader)
400401
.await
401402
.unwrap()
@@ -405,7 +406,7 @@ mod tests {
405406
let files = &[FileMeta {
406407
location: url.clone(),
407408
last_modified: meta.last_modified.timestamp(),
408-
size: meta.size,
409+
size: meta.size as usize,
409410
}];
410411

411412
let handler = DefaultParquetHandler::new(store, Arc::new(TokioBackgroundExecutor::new()));
@@ -513,13 +514,14 @@ mod tests {
513514

514515
let filename = location.path().split('/').next_back().unwrap();
515516
assert_eq!(&expected_location.join(filename).unwrap(), location);
516-
assert_eq!(expected_size, size);
517+
assert_eq!(expected_size, size as u64);
517518
assert!(now - last_modified < 10_000);
518519

519520
// check we can read back
520521
let path = Path::from(location.path());
521522
let meta = store.head(&path).await.unwrap();
522-
let reader = ParquetObjectReader::new(store.clone(), meta.clone());
523+
let reader = ParquetObjectReader::new(store.clone(), meta.location)
524+
.with_file_size(meta.size);
523525
let physical_schema = ParquetRecordBatchStreamBuilder::new(reader)
524526
.await
525527
.unwrap()

0 commit comments

Comments
 (0)