From e7a16b8960879edac1cd69da01d9ba83ec79f6e8 Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Tue, 13 Mar 2018 12:28:46 +0100 Subject: [PATCH] Bump rustc-test to 0.3 Signed-off-by: Igor Gnatenko --- ...test-0.3-unbreak-tests-on-nightly-20.patch | 30 +++++++++++++++++++ rust-url.spec | 12 ++++++-- url-1.7.0-fix-metadata.diff | 11 +++++++ 3 files changed, 51 insertions(+), 2 deletions(-) create mode 100644 0001-Update-to-rustc_test-0.3-unbreak-tests-on-nightly-20.patch create mode 100644 url-1.7.0-fix-metadata.diff diff --git a/0001-Update-to-rustc_test-0.3-unbreak-tests-on-nightly-20.patch b/0001-Update-to-rustc_test-0.3-unbreak-tests-on-nightly-20.patch new file mode 100644 index 0000000..8df7c73 --- /dev/null +++ b/0001-Update-to-rustc_test-0.3-unbreak-tests-on-nightly-20.patch @@ -0,0 +1,30 @@ +From 9d500e76a0e1644c93b3869588f979e4440e74d6 Mon Sep 17 00:00:00 2001 +From: Simon Sapin +Date: Sun, 25 Feb 2018 08:21:55 +0100 +Subject: [PATCH] Update to rustc_test 0.3, unbreak tests on nightly-2018-02-25 + +Version 0.2 of the crates.io package `rustc_test` uses `test` as its +rustc crate name, shadowing the `test` crate from the standard library. +This made up subject to breaking changes to its private APIs: + +https://travis-ci.org/SimonSapin/run-nightly/builds/345808272#L549 +--- + tests/data.rs | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/data.rs b/tests/data.rs +index 8885f64..e9203b1 100644 +--- a/tests/data.rs ++++ b/tests/data.rs +@@ -9,7 +9,7 @@ + //! Data-driven tests + + extern crate rustc_serialize; +-extern crate test; ++extern crate rustc_test as test; + extern crate url; + + use rustc_serialize::json::{self, Json}; +-- +2.16.2 + diff --git a/rust-url.spec b/rust-url.spec index 50ca29e..bbb92e7 100644 --- a/rust-url.spec +++ b/rust-url.spec @@ -6,12 +6,17 @@ Name: rust-%{crate} Version: 1.7.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: URL library for Rust, based on the WHATWG URL Standard License: MIT or ASL 2.0 URL: https://crates.io/crates/url Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate +# Initial patched metadata +# * Bump rustc-test to 0.3, https://github.com/servo/rust-url/commit/9d500e76a0e1644c93b3869588f979e4440e74d6 +Patch0: url-1.7.0-fix-metadata.diff +# Make it work with new rustc-test +Patch1: 0001-Update-to-rustc_test-0.3-unbreak-tests-on-nightly-20.patch ExclusiveArch: %{rust_arches} @@ -27,7 +32,7 @@ BuildRequires: (crate(serde) >= 0.6.1 with crate(serde) < 0.9.0) %if %{with check} # [dev-dependencies] BuildRequires: (crate(rustc-serialize) >= 0.3.0 with crate(rustc-serialize) < 0.4.0) -BuildRequires: (crate(rustc-test) >= 0.2.0 with crate(rustc-test) < 0.3.0) +BuildRequires: (crate(rustc-test) >= 0.3.0 with crate(rustc-test) < 0.4.0) BuildRequires: (crate(serde_json) >= 0.6.1 with crate(serde_json) < 0.9.0) %endif @@ -67,6 +72,9 @@ which use %{crate} from crates.io. %exclude %{cargo_registry}/%{crate}-%{version}/{appveyor.yml,docs} %changelog +* Tue Mar 13 2018 Igor Gnatenko - 1.7.0-2 +- Bump rustc-test to 0.3 + * Wed Feb 21 2018 Igor Gnatenko - 1.7.0-1 - Update to 1.7.0 diff --git a/url-1.7.0-fix-metadata.diff b/url-1.7.0-fix-metadata.diff new file mode 100644 index 0000000..c554725 --- /dev/null +++ b/url-1.7.0-fix-metadata.diff @@ -0,0 +1,11 @@ +--- url-1.7.0/Cargo.toml 1970-01-01T01:00:00+01:00 ++++ url-1.7.0/Cargo.toml 2018-03-13T12:28:19.050950+01:00 +@@ -61,7 +61,7 @@ + version = "0.3" + + [dev-dependencies.rustc-test] +-version = "0.2" ++version = "0.3" + + [dev-dependencies.serde_json] + version = ">=0.6.1, <0.9"