diff options
| author | Tinco Andringa <mail@tinco.nl> | 2018-07-11 15:21:14 +0200 |
|---|---|---|
| committer | Tinco Andringa <mail@tinco.nl> | 2018-07-11 15:21:14 +0200 |
| commit | f0b1a781acebee0f3783377603cead74c9c7c2f5 (patch) | |
| tree | c08cf434c0b247bc11d8f891e3f25b09a2c09194 /src | |
| parent | ce45cbb053bdde569b49ef12125c26158cf2ca79 (diff) | |
make pretty source comparison check be fatal (fixes #52255)
Diffstat (limited to 'src')
| -rw-r--r-- | src/tools/compiletest/src/runtest.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs index 408eda5ba5b..59ddc16715d 100644 --- a/src/tools/compiletest/src/runtest.rs +++ b/src/tools/compiletest/src/runtest.rs @@ -519,9 +519,8 @@ impl<'test> TestCx<'test> { fn compare_source(&self, expected: &str, actual: &str) { if expected != actual { - self.error("pretty-printed source does not match expected source"); - println!( - "\n\ + self.fatal(&format!( + "pretty-printed source does not match expected source\n\ expected:\n\ ------------------------------------------\n\ {}\n\ @@ -531,7 +530,7 @@ impl<'test> TestCx<'test> { {}\n\ ------------------------------------------\n\ \n", - expected, actual + expected, actual) ); } } |
