Skip to content

Commit

Permalink
More import path fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
mkeeter committed Feb 16, 2024
1 parent f548fbd commit 2fc78fd
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions downstairs/src/region.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1267,6 +1267,7 @@ pub fn config_path<P: AsRef<Path>>(dir: P) -> PathBuf {

#[cfg(test)]
pub(crate) mod test {
use bytes::Bytes;
use std::fs::rename;
use std::path::PathBuf;

Expand Down Expand Up @@ -3501,7 +3502,7 @@ pub(crate) mod test {
// We use the "all 9's data" and checksum.
fn create_generic_write(
eid: u64,
offset: crucible::Block,
offset: crucible_common::Block,
) -> Vec<crucible_protocol::Write> {
let data = BytesMut::from(&[9u8; 512][..]);
let writes: Vec<crucible_protocol::Write> =
Expand Down Expand Up @@ -4087,7 +4088,7 @@ pub(crate) mod test {
let (_dir, mut region, data) = prepare_random_region().await?;

// Call region_read with a single large contiguous range
let requests: Vec<crucible::ReadRequest> = (1..8)
let requests: Vec<crucible_protocol::ReadRequest> = (1..8)
.map(|i| crucible_protocol::ReadRequest {
eid: 0,
offset: Block::new_512(i),
Expand All @@ -4114,7 +4115,7 @@ pub(crate) mod test {

// Call region_read with a single large contiguous range that spans
// multiple extents
let requests: Vec<crucible::ReadRequest> = (9..28)
let requests: Vec<crucible_protocol::ReadRequest> = (9..28)
.map(|i| crucible_protocol::ReadRequest {
eid: i / 10,
offset: Block::new_512(i % 10),
Expand All @@ -4140,25 +4141,25 @@ pub(crate) mod test {
let (_dir, mut region, data) = prepare_random_region().await?;

// Call region_read with a multiple disjoint large contiguous ranges
let requests: Vec<crucible::ReadRequest> = vec![
let requests: Vec<crucible_protocol::ReadRequest> = vec![
(1..4)
.map(|i| crucible_protocol::ReadRequest {
eid: i / 10,
offset: Block::new_512(i % 10),
})
.collect::<Vec<crucible::ReadRequest>>(),
.collect::<Vec<crucible_protocol::ReadRequest>>(),
(15..24)
.map(|i| crucible_protocol::ReadRequest {
eid: i / 10,
offset: Block::new_512(i % 10),
})
.collect::<Vec<crucible::ReadRequest>>(),
.collect::<Vec<crucible_protocol::ReadRequest>>(),
(27..28)
.map(|i| crucible_protocol::ReadRequest {
eid: i / 10,
offset: Block::new_512(i % 10),
})
.collect::<Vec<crucible::ReadRequest>>(),
.collect::<Vec<crucible_protocol::ReadRequest>>(),
]
.into_iter()
.flatten()
Expand Down Expand Up @@ -4188,7 +4189,7 @@ pub(crate) mod test {
let (_dir, mut region, data) = prepare_random_region().await?;

// Call region_read with a multiple disjoint non-contiguous ranges
let requests: Vec<crucible::ReadRequest> = vec![
let requests: Vec<crucible_protocol::ReadRequest> = vec![
crucible_protocol::ReadRequest {
eid: 0,
offset: Block::new_512(0),
Expand Down

0 comments on commit 2fc78fd

Please sign in to comment.