Opt-out all other failing tests

Looks like cargo traverses the filesystem & fails if it runs into a
Cargo.toml that doesn't declare a target.  I couldn't find a nice way to
re-engineer the test to avoid this issue.  So I'll leave that as someone
else's exercise.
This commit is contained in:
Dale Wijnand 2018-07-24 13:59:42 +01:00
parent d2c815be22
commit 252f6e8e9f
No known key found for this signature in database
GPG key ID: 4F256E3D151DF5EF
10 changed files with 23 additions and 4 deletions

View file

@ -24,6 +24,7 @@ fn pkg(name: &str, vers: &str) {
#[test]
fn multiple_installs() {
let p = project()
.no_manifest()
.file(
"a/Cargo.toml",
r#"
@ -103,6 +104,7 @@ fn concurrent_installs() {
#[test]
fn one_install_should_be_bad() {
let p = project()
.no_manifest()
.file(
"a/Cargo.toml",
r#"
@ -169,6 +171,7 @@ fn multiple_registry_fetches() {
pkg.publish();
let p = project()
.no_manifest()
.file(
"a/Cargo.toml",
r#"
@ -255,6 +258,7 @@ fn git_same_repo_different_tags() {
git::tag(&repo, "tag2");
let p = project()
.no_manifest()
.file(
"a/Cargo.toml",
&format!(
@ -334,6 +338,7 @@ fn git_same_branch_different_revs() {
}).unwrap();
let p = project()
.no_manifest()
.file(
"a/Cargo.toml",
&format!(

View file

@ -60,6 +60,11 @@ impl VendorPackage {
self
}
fn no_manifest(mut self) -> Self {
self.p = self.p.map(|pb| pb.no_manifest());
self
}
fn build(&mut self) {
let p = self.p.take().unwrap();
let json = serde_json::to_string(&self.cksum).unwrap();
@ -604,7 +609,7 @@ fn only_dot_files_ok() {
)
.file("src/lib.rs", "")
.build();
VendorPackage::new("foo").file(".bar", "").build();
VendorPackage::new("foo").no_manifest().file(".bar", "").build();
let p = project()
.file(
@ -642,6 +647,7 @@ fn random_files_ok() {
.file("src/lib.rs", "")
.build();
VendorPackage::new("foo")
.no_manifest()
.file("bar", "")
.file("../test", "")
.build();

View file

@ -237,6 +237,7 @@ fn fix_path_deps() {
#[test]
fn do_not_fix_non_relevant_deps() {
let p = project()
.no_manifest()
.file(
"foo/Cargo.toml",
r#"

View file

@ -320,6 +320,7 @@ fn changing_profiles_caches_targets() {
fn changing_bin_paths_common_target_features_caches_targets() {
// Make sure dep_cache crate is built once per feature
let p = project()
.no_manifest()
.file(
".cargo/config",
r#"
@ -731,6 +732,7 @@ fn rerun_if_changed_in_dep() {
#[test]
fn same_build_dir_cached_packages() {
let p = project()
.no_manifest()
.file(
"a1/Cargo.toml",
r#"

View file

@ -540,7 +540,7 @@ fn package_git_submodule() {
)
.file("src/lib.rs", "pub fn foo() {}")
}).unwrap();
let library = git::new("bar", |library| library.file("Makefile", "all:")).unwrap();
let library = git::new("bar", |library| library.no_manifest().file("Makefile", "all:")).unwrap();
let repository = git2::Repository::open(&project.root()).unwrap();
let url = path2url(library.root()).to_string();

View file

@ -1085,6 +1085,7 @@ fn custom_target_no_rebuild() {
#[test]
fn override_and_depend() {
let p = project()
.no_manifest()
.file(
"a/a1/Cargo.toml",
r#"

View file

@ -512,7 +512,7 @@ fn publish_clean() {
fn publish_in_sub_repo() {
publish::setup();
let p = project().file("baz", "").build();
let p = project().no_manifest().file("baz", "").build();
let _ = repo(&paths::root().join("foo"))
.file(
@ -578,7 +578,7 @@ fn publish_when_ignored() {
fn ignore_when_crate_ignored() {
publish::setup();
let p = project().file("bar/baz", "").build();
let p = project().no_manifest().file("bar/baz", "").build();
let _ = repo(&paths::root().join("foo"))
.file(".gitignore", "bar")

View file

@ -1329,6 +1329,7 @@ fn fail_no_extra_verbose() {
#[test]
fn run_multiple_packages() {
let p = project()
.no_manifest()
.file(
"foo/Cargo.toml",
r#"

View file

@ -127,6 +127,7 @@ fn relative_tools() {
// Funky directory structure to test that relative tool paths are made absolute
// by reference to the `.cargo/..` directory and not to (for example) the CWD.
let p = project()
.no_manifest()
.file(
"bar/Cargo.toml",
r#"

View file

@ -1544,6 +1544,7 @@ fn relative_path_for_root_works() {
#[test]
fn path_dep_outside_workspace_is_not_member() {
let p = project()
.no_manifest()
.file(
"ws/Cargo.toml",
r#"
@ -1580,6 +1581,7 @@ fn path_dep_outside_workspace_is_not_member() {
#[test]
fn test_in_and_out_of_workspace() {
let p = project()
.no_manifest()
.file(
"ws/Cargo.toml",
r#"