From d91457495b2f551e34ecbe1111885d6ccceceb15 Mon Sep 17 00:00:00 2001 From: kennytm Date: Tue, 3 Jul 2018 04:49:42 +0800 Subject: [PATCH 1/3] Fix the tool's path in toolstate verification. This ensure we do block the tools when they are broken during an update. --- src/ci/docker/x86_64-gnu-tools/checktools.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ci/docker/x86_64-gnu-tools/checktools.sh b/src/ci/docker/x86_64-gnu-tools/checktools.sh index 56e637249f5ca..e8197e9085182 100755 --- a/src/ci/docker/x86_64-gnu-tools/checktools.sh +++ b/src/ci/docker/x86_64-gnu-tools/checktools.sh @@ -79,11 +79,11 @@ status_check() { check_dispatch $1 beta nomicon src/doc/nomicon check_dispatch $1 beta reference src/doc/reference check_dispatch $1 beta rust-by-example src/doc/rust-by-example - check_dispatch $1 beta rls src/tool/rls - check_dispatch $1 beta rustfmt src/tool/rustfmt + check_dispatch $1 beta rls src/tools/rls + check_dispatch $1 beta rustfmt src/tools/rustfmt # these tools are not required for beta to successfully branch - check_dispatch $1 nightly clippy-driver src/tool/clippy - check_dispatch $1 nightly miri src/tool/miri + check_dispatch $1 nightly clippy-driver src/tools/clippy + check_dispatch $1 nightly miri src/tools/miri } # If this PR is intended to update one of these tools, do not let the build pass From 20231d774bcda2d6f9bd52fe402fd22f2d22d223 Mon Sep 17 00:00:00 2001 From: kennytm Date: Tue, 3 Jul 2018 05:53:18 +0800 Subject: [PATCH 2/3] Fixed detection of test-fail for doctests. --- src/bootstrap/test.rs | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs index 90688b1c0e181..3adfbb5e36b51 100644 --- a/src/bootstrap/test.rs +++ b/src/bootstrap/test.rs @@ -1269,17 +1269,15 @@ impl Step for DocTest { files.sort(); + let mut toolstate = ToolState::TestPass; for file in files { - let test_result = markdown_test(builder, compiler, &file); - if self.is_ext_doc { - let toolstate = if test_result { - ToolState::TestPass - } else { - ToolState::TestFail - }; - builder.save_toolstate(self.name, toolstate); + if !markdown_test(builder, compiler, &file) { + toolstate = ToolState::TestFail; } } + if self.is_ext_doc { + builder.save_toolstate(self.name, toolstate); + } } } From 689cffa211e4c2c2c74dbc759020be40fe222d23 Mon Sep 17 00:00:00 2001 From: kennytm Date: Tue, 3 Jul 2018 06:01:58 +0800 Subject: [PATCH 3/3] Run "tools" job on PR when commit message starts with "Update RLS/miri/..." --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 2e6722cf85563..ba8a39f355c4b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -169,7 +169,7 @@ matrix: - env: IMAGE=x86_64-gnu-aux if: branch = auto - env: IMAGE=x86_64-gnu-tools - if: branch = auto + if: branch = auto OR (type = pull_request AND commit_message =~ /(?i:^update.*\b(rls|rustfmt|clippy|miri)\b)/) - env: IMAGE=x86_64-gnu-debug if: branch = auto - env: IMAGE=x86_64-gnu-nopt