Skip to content

Commit 379e1dd

Browse files
authored
Merge pull request #2756 from reubenmiller/test-move-conditional-import
tests: move import into test which is only run on linux targets
2 parents ff5eee4 + 5809017 commit 379e1dd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/common/download/src/download.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -488,7 +488,6 @@ fn try_pre_allocate_space(file: &File, path: &Path, file_len: u64) -> Result<(),
488488
#[allow(deprecated)]
489489
mod tests {
490490
use super::*;
491-
use nix::sys::statvfs;
492491
use std::io::Write;
493492
use tempfile::tempdir;
494493
use tempfile::NamedTempFile;
@@ -558,6 +557,7 @@ mod tests {
558557
#[tokio::test]
559558
#[ignore = "Overriding Content-Length doesn't work in mockito"]
560559
async fn downloader_download_with_content_length_larger_than_usable_disk_space() {
560+
use nix::sys::statvfs;
561561
let tmpstats = statvfs::statvfs("/tmp").unwrap();
562562
let usable_disk_space = tmpstats.blocks_free() * tmpstats.block_size();
563563

0 commit comments

Comments
 (0)