From 4f02ec2cea496445b650ba686b3ef49f2f4150c4 Mon Sep 17 00:00:00 2001 From: Scott Schafer Date: Tue, 16 Sep 2025 01:53:23 -0600 Subject: test: Use SVG for terminal url test --- tests/ui/diagnostic-flags/terminal_urls.rs | 4 +- tests/ui/diagnostic-flags/terminal_urls.stderr | 11 ----- tests/ui/diagnostic-flags/terminal_urls.svg | 48 +++++++++++++++++++++ .../ui/diagnostic-flags/terminal_urls.windows.svg | 49 ++++++++++++++++++++++ 4 files changed, 99 insertions(+), 13 deletions(-) delete mode 100644 tests/ui/diagnostic-flags/terminal_urls.stderr create mode 100644 tests/ui/diagnostic-flags/terminal_urls.svg create mode 100644 tests/ui/diagnostic-flags/terminal_urls.windows.svg diff --git a/tests/ui/diagnostic-flags/terminal_urls.rs b/tests/ui/diagnostic-flags/terminal_urls.rs index 3c74e992395..631512ab579 100644 --- a/tests/ui/diagnostic-flags/terminal_urls.rs +++ b/tests/ui/diagnostic-flags/terminal_urls.rs @@ -1,4 +1,4 @@ -//@ compile-flags: -Zterminal-urls=yes +//@ compile-flags: -Zterminal-urls=yes --error-format=human --color=always fn main() { - let () = 4; //~ ERROR + let () = 4; } diff --git a/tests/ui/diagnostic-flags/terminal_urls.stderr b/tests/ui/diagnostic-flags/terminal_urls.stderr deleted file mode 100644 index e5dfcdf6431..00000000000 --- a/tests/ui/diagnostic-flags/terminal_urls.stderr +++ /dev/null @@ -1,11 +0,0 @@ -error[]8;;https://doc.rust-lang.org/error_codes/E0308.htmlE0308]8;;]: mismatched types - --> $DIR/terminal_urls.rs:3:9 - | -LL | let () = 4; - | ^^ - this expression has type `{integer}` - | | - | expected integer, found `()` - -error: aborting due to 1 previous error - -For more information about this error, try `rustc --explain E0308`. diff --git a/tests/ui/diagnostic-flags/terminal_urls.svg b/tests/ui/diagnostic-flags/terminal_urls.svg new file mode 100644 index 00000000000..fcb65637c4a --- /dev/null +++ b/tests/ui/diagnostic-flags/terminal_urls.svg @@ -0,0 +1,48 @@ + + + + + + + error[E0308]: mismatched types + + --> $DIR/terminal_urls.rs:3:9 + + | + + LL | let () = 4; + + | ^^ - this expression has type `{integer}` + + | | + + | expected integer, found `()` + + + + error: aborting due to 1 previous error + + + + For more information about this error, try `rustc --explain E0308`. + + + + + + diff --git a/tests/ui/diagnostic-flags/terminal_urls.windows.svg b/tests/ui/diagnostic-flags/terminal_urls.windows.svg new file mode 100644 index 00000000000..e7b46638399 --- /dev/null +++ b/tests/ui/diagnostic-flags/terminal_urls.windows.svg @@ -0,0 +1,49 @@ + + + + + + + error[E0308]: mismatched types + + --> $DIR/terminal_urls.rs:3:9 + + | + + LL | let () = 4; + + | ^^ - this expression has type `{integer}` + + | | + + | expected integer, found `()` + + + + error: aborting due to 1 previous error + + + + For more information about this error, try `rustc --explain E0308`. + + + + + + -- cgit 1.4.1-3-g733a5