Auto merge of #22323 - servo:letitgo, r=jdm

Don’t run warnings into errors when trying Nightly

See for example https://tools.taskcluster.net/groups/bLE1RGeHTROuhEil2SmOXA/tasks/BURjOZ1JTvqafiscoEYzfQ/runs/0/logs/public%2Flogs%2Flive.log , which would otherwise require a rustup to fix.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/22323)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-11-30 08:21:44 -05:00 committed by GitHub
commit be206f3e5f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -43,7 +43,7 @@ log_artifacts_expire_in = "1 year"
build_env = { build_env = {
"RUST_BACKTRACE": "1", "RUST_BACKTRACE": "1",
"RUSTFLAGS": "-Dwarnings", "RUSTFLAGS": "-Dwarnings", # If changing this, also adjust with_rust_nightly()
"CARGO_INCREMENTAL": "0", "CARGO_INCREMENTAL": "0",
} }
unix_build_env = { unix_build_env = {
@ -100,11 +100,21 @@ def macos_unit():
def with_rust_nightly(): def with_rust_nightly():
return linux_build_task("Linux x64: with Rust Nightly").with_script(""" modified_build_env = dict(build_env)
echo "nightly" > rust-toolchain flags = build_env.pop("RUSTFLAGS").split(" ")
./mach build --dev flags.remove("-Dwarnings")
./mach test-unit if flags: # pragma: no cover
""").create() modified_build_env["RUSTFLAGS"] = " ".join(flags)
return (
linux_build_task("Linux x64: with Rust Nightly", build_env=modified_build_env)
.with_script("""
echo "nightly" > rust-toolchain
./mach build --dev
./mach test-unit
""")
.create()
)
def android_arm32(): def android_arm32():
@ -304,7 +314,7 @@ def macos_task(name):
) )
def linux_build_task(name): def linux_build_task(name, *, build_env=build_env):
return ( return (
linux_task(name) linux_task(name)
# https://docs.taskcluster.net/docs/reference/workers/docker-worker/docs/caches # https://docs.taskcluster.net/docs/reference/workers/docker-worker/docs/caches