Skip to content

Commit

Permalink
Fixed detection of test-fail for doctests.
Browse files Browse the repository at this point in the history
  • Loading branch information
kennytm committed Jul 2, 2018
1 parent d914574 commit 20231d7
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions src/bootstrap/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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);
}
}
}

Expand Down

0 comments on commit 20231d7

Please sign in to comment.