Skip to content

Commit a88fbac

Browse files
committed
Auto merge of #4876 - MaloJaffre:flate2, r=alexcrichton
Upgrade flate2 crate to 1.0 in cargotest I've missed this part in my previous PR, sorry. Unblocks rust#46278.
2 parents fdf01c6 + f8b32c9 commit a88fbac

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

tests/cargotest/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ path = "lib.rs"
99
[dependencies]
1010
cargo = { path = "../.." }
1111
filetime = "0.1"
12-
flate2 = "0.2"
12+
flate2 = "1.0"
1313
git2 = { version = "0.6", default-features = false }
1414
hamcrest = "=0.1.1"
1515
hex = "0.2"

tests/cargotest/support/registry.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use std::fs::{self, File};
33
use std::io::prelude::*;
44
use std::path::{PathBuf, Path};
55

6-
use flate2::Compression::Default;
6+
use flate2::Compression;
77
use flate2::write::GzEncoder;
88
use git2;
99
use hex::ToHex;
@@ -273,7 +273,8 @@ impl Package {
273273
let dst = self.archive_dst();
274274
t!(fs::create_dir_all(dst.parent().unwrap()));
275275
let f = t!(File::create(&dst));
276-
let mut a = Builder::new(GzEncoder::new(f, Default));
276+
let mut a =
277+
Builder::new(GzEncoder::new(f, Compression::default()));
277278
self.append(&mut a, "Cargo.toml", &manifest);
278279
if self.files.is_empty() {
279280
self.append(&mut a, "src/lib.rs", "");

0 commit comments

Comments
 (0)