From 80c140d49c7d826ae3cea3fd41de7442d57cc817 Mon Sep 17 00:00:00 2001 From: Joshua Barretto Date: Mon, 28 Oct 2024 22:34:07 +0000 Subject: [PATCH] Fixed poor build API --- examples/multifile.rs | 2 +- examples/multiline.rs | 2 +- examples/simple.rs | 4 +- examples/stresstest.rs | 2 +- src/.write.rs.pending-snap | 147 +++++++++++++++++++++++++++++++++++++ src/lib.rs | 14 ++-- src/write.rs | 50 ++++++------- 7 files changed, 182 insertions(+), 39 deletions(-) create mode 100644 src/.write.rs.pending-snap diff --git a/examples/multifile.rs b/examples/multifile.rs index f135649..711c58d 100644 --- a/examples/multifile.rs +++ b/examples/multifile.rs @@ -8,7 +8,7 @@ fn main() { let b = colors.next(); let c = colors.next(); - Report::build(ReportKind::Error, "b.tao", 10) + Report::build(ReportKind::Error, ("b.tao", 10..14)) .with_code(3) .with_message("Cannot add types Nat and Str".to_string()) .with_label( diff --git a/examples/multiline.rs b/examples/multiline.rs index e44f508..f5e94a1 100644 --- a/examples/multiline.rs +++ b/examples/multiline.rs @@ -9,7 +9,7 @@ fn main() { let out = Color::Fixed(81); let out2 = colors.next(); - Report::build(ReportKind::Error, "sample.tao", 12) + Report::build(ReportKind::Error, ("sample.tao", 32..33)) .with_code(3) .with_message("Incompatible types".to_string()) .with_label( diff --git a/examples/simple.rs b/examples/simple.rs index 2c8827d..2ed5ef0 100644 --- a/examples/simple.rs +++ b/examples/simple.rs @@ -1,7 +1,7 @@ use ariadne::{Color, Config, Label, Report, ReportKind, Source}; fn main() { - Report::build(ReportKind::Error, (), 34) + Report::build(ReportKind::Error, 34..34) .with_message("Incompatible types") .with_label(Label::new(32..33).with_message("This is of type Nat")) .with_label(Label::new(42..45).with_message("This is of type Str")) @@ -11,7 +11,7 @@ fn main() { const SOURCE: &str = "a b c d e f"; // also supports labels with no messages to only emphasis on some areas - Report::build(ReportKind::Error, (), 34) + Report::build(ReportKind::Error, 2..3) .with_message("Incompatible types") .with_config(Config::default().with_compact(true)) .with_label(Label::new(0..1).with_color(Color::Red)) diff --git a/examples/stresstest.rs b/examples/stresstest.rs index 3f3064a..798e236 100644 --- a/examples/stresstest.rs +++ b/examples/stresstest.rs @@ -3,7 +3,7 @@ use ariadne::{Color, ColorGenerator, Config, Label, Report, ReportKind, Source}; fn main() { let mut colors = ColorGenerator::new(); - Report::build(ReportKind::Error, "stresstest.tao", 13) + Report::build(ReportKind::Error, ("stresstest.tao", 13..13)) .with_code(3) .with_message("Incompatible types".to_string()) .with_label( diff --git a/src/.write.rs.pending-snap b/src/.write.rs.pending-snap new file mode 100644 index 0000000..a6d4a24 --- /dev/null +++ b/src/.write.rs.pending-snap @@ -0,0 +1,147 @@ +{"run_id":"1730154368-841895824","line":1139,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input","metadata":{"source":"src/write.rs","assertion_line":1139,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n---'"}} +{"run_id":"1730154368-841895824","line":1072,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_column","metadata":{"source":"src/write.rs","assertion_line":1072,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154368-841895824","line":1185,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_note","metadata":{"source":"src/write.rs","assertion_line":1185,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154368-841895824","line":1161,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help","metadata":{"source":"src/write.rs","assertion_line":1161,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n---'"}} +{"run_id":"1730154368-841895824","line":1048,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_label","metadata":{"source":"src/write.rs","assertion_line":1048,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154368-841895824","line":1332,"new":{"module_name":"ariadne__write__tests","snapshot_name":"note","metadata":{"source":"src/write.rs","assertion_line":1332,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154368-841895824","line":1250,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiline_label","metadata":{"source":"src/write.rs","assertion_line":1250,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | ,-> apple\n : : \n 3 | |-> orange\n | | \n | `----------- illegal comparison\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | ,-> apple\n : :\n 3 | |-> orange\n | |\n | `----------- illegal comparison\n---'"}} +{"run_id":"1730154368-841895824","line":1385,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help_and_note","metadata":{"source":"src/write.rs","assertion_line":1385,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154368-841895824","line":1358,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help","metadata":{"source":"src/write.rs","assertion_line":1358,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n---'"}} +{"run_id":"1730154368-841895824","line":1462,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_multi_lines","metadata":{"source":"src/write.rs","assertion_line":1462,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'"}} +{"run_id":"1730154368-841895824","line":1118,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_of_width_zero_at_end_of_line","metadata":{"source":"src/write.rs","assertion_line":1118,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | | \n | `- Unexpected end of file\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | |\n | `- Unexpected end of file\n---'"}} +{"run_id":"1730154368-841895824","line":1210,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help_note","metadata":{"source":"src/write.rs","assertion_line":1210,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154368-841895824","line":1436,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_single_lines","metadata":{"source":"src/write.rs","assertion_line":1436,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n---'"}} +{"run_id":"1730154368-841895824","line":964,"new":null,"old":null} +{"run_id":"1730154368-841895824","line":1097,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_at_end_of_long_line","metadata":{"source":"src/write.rs","assertion_line":1097,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^ \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^\n | `---- This is an orange\n---'"}} +{"run_id":"1730154368-841895824","line":980,"new":null,"old":null} +{"run_id":"1730154368-841895824","line":1024,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_byte_chars","metadata":{"source":"src/write.rs","assertion_line":1024,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154368-841895824","line":1300,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiple_labels_same_span","metadata":{"source":"src/write.rs","assertion_line":1300,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | | \n | `-------------- Have I mentioned that this is an apple?\n | | | \n | `-------------- No really, have I mentioned that?\n | | \n | `---- This is an orange\n | | \n | `---- Have I mentioned that this is an orange?\n | | \n | `---- No really, have I mentioned that?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | | |\n | `-------------- Have I mentioned that this is an apple?\n | | |\n | `-------------- No really, have I mentioned that?\n | |\n | `---- This is an orange\n | |\n | `---- Have I mentioned that this is an orange?\n | |\n | `---- No really, have I mentioned that?\n---'"}} +{"run_id":"1730154368-841895824","line":1273,"new":{"module_name":"ariadne__write__tests","snapshot_name":"partially_overlapping_labels","metadata":{"source":"src/write.rs","assertion_line":1273,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^ \n | `------------------- scheme\n | | \n | `----------- URL\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^\n | `------------------- scheme\n | |\n | `----------- URL\n---'"}} +{"run_id":"1730154368-841895824","line":1412,"new":{"module_name":"ariadne__write__tests","snapshot_name":"single_note_single_line","metadata":{"source":"src/write.rs","assertion_line":1412,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note: No need to try, they can't be compared.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note: No need to try, they can't be compared.\n---'"}} +{"run_id":"1730154368-841895824","line":1000,"new":{"module_name":"ariadne__write__tests","snapshot_name":"two_labels_with_messages","metadata":{"source":"src/write.rs","assertion_line":1000,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n---'"}} +{"run_id":"1730154463-339062648","line":1139,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1072,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1048,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1210,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1185,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1161,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1358,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1385,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1436,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1118,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1024,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1332,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1462,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1097,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1300,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":964,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1250,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1273,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1412,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":980,"new":null,"old":null} +{"run_id":"1730154463-339062648","line":1000,"new":null,"old":null} +{"run_id":"1730154470-722757339","line":1139,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input","metadata":{"source":"src/write.rs","assertion_line":1139,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n---'"}} +{"run_id":"1730154470-722757339","line":1118,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_of_width_zero_at_end_of_line","metadata":{"source":"src/write.rs","assertion_line":1118,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | | \n | `- Unexpected end of file\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | |\n | `- Unexpected end of file\n---'"}} +{"run_id":"1730154470-722757339","line":1185,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_note","metadata":{"source":"src/write.rs","assertion_line":1185,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154470-722757339","line":1048,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_label","metadata":{"source":"src/write.rs","assertion_line":1048,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154470-722757339","line":1072,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_column","metadata":{"source":"src/write.rs","assertion_line":1072,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154470-722757339","line":1024,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_byte_chars","metadata":{"source":"src/write.rs","assertion_line":1024,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154470-722757339","line":1161,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help","metadata":{"source":"src/write.rs","assertion_line":1161,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n---'"}} +{"run_id":"1730154470-722757339","line":1462,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_multi_lines","metadata":{"source":"src/write.rs","assertion_line":1462,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'"}} +{"run_id":"1730154470-722757339","line":1436,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_single_lines","metadata":{"source":"src/write.rs","assertion_line":1436,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n---'"}} +{"run_id":"1730154470-722757339","line":1358,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help","metadata":{"source":"src/write.rs","assertion_line":1358,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n---'"}} +{"run_id":"1730154470-722757339","line":1332,"new":{"module_name":"ariadne__write__tests","snapshot_name":"note","metadata":{"source":"src/write.rs","assertion_line":1332,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154470-722757339","line":1210,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help_note","metadata":{"source":"src/write.rs","assertion_line":1210,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154470-722757339","line":1300,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiple_labels_same_span","metadata":{"source":"src/write.rs","assertion_line":1300,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | | \n | `-------------- Have I mentioned that this is an apple?\n | | | \n | `-------------- No really, have I mentioned that?\n | | \n | `---- This is an orange\n | | \n | `---- Have I mentioned that this is an orange?\n | | \n | `---- No really, have I mentioned that?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | | |\n | `-------------- Have I mentioned that this is an apple?\n | | |\n | `-------------- No really, have I mentioned that?\n | |\n | `---- This is an orange\n | |\n | `---- Have I mentioned that this is an orange?\n | |\n | `---- No really, have I mentioned that?\n---'"}} +{"run_id":"1730154470-722757339","line":964,"new":null,"old":null} +{"run_id":"1730154470-722757339","line":1097,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_at_end_of_long_line","metadata":{"source":"src/write.rs","assertion_line":1097,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^ \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^\n | `---- This is an orange\n---'"}} +{"run_id":"1730154470-722757339","line":980,"new":null,"old":null} +{"run_id":"1730154470-722757339","line":1385,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help_and_note","metadata":{"source":"src/write.rs","assertion_line":1385,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154470-722757339","line":1250,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiline_label","metadata":{"source":"src/write.rs","assertion_line":1250,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | ,-> apple\n : : \n 3 | |-> orange\n | | \n | `----------- illegal comparison\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | ,-> apple\n : :\n 3 | |-> orange\n | |\n | `----------- illegal comparison\n---'"}} +{"run_id":"1730154470-722757339","line":1000,"new":{"module_name":"ariadne__write__tests","snapshot_name":"two_labels_with_messages","metadata":{"source":"src/write.rs","assertion_line":1000,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n---'"}} +{"run_id":"1730154470-722757339","line":1273,"new":{"module_name":"ariadne__write__tests","snapshot_name":"partially_overlapping_labels","metadata":{"source":"src/write.rs","assertion_line":1273,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^ \n | `------------------- scheme\n | | \n | `----------- URL\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^\n | `------------------- scheme\n | |\n | `----------- URL\n---'"}} +{"run_id":"1730154470-722757339","line":1412,"new":{"module_name":"ariadne__write__tests","snapshot_name":"single_note_single_line","metadata":{"source":"src/write.rs","assertion_line":1412,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note: No need to try, they can't be compared.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note: No need to try, they can't be compared.\n---'"}} +{"run_id":"1730154580-873153354","line":1048,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_label","metadata":{"source":"src/write.rs","assertion_line":1048,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154580-873153354","line":964,"new":null,"old":null} +{"run_id":"1730154580-873153354","line":1024,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_byte_chars","metadata":{"source":"src/write.rs","assertion_line":1024,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154580-873153354","line":1358,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help","metadata":{"source":"src/write.rs","assertion_line":1358,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n---'"}} +{"run_id":"1730154580-873153354","line":1385,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help_and_note","metadata":{"source":"src/write.rs","assertion_line":1385,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154580-873153354","line":980,"new":null,"old":null} +{"run_id":"1730154580-873153354","line":1118,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_of_width_zero_at_end_of_line","metadata":{"source":"src/write.rs","assertion_line":1118,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | | \n | `- Unexpected end of file\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | |\n | `- Unexpected end of file\n---'"}} +{"run_id":"1730154580-873153354","line":1139,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input","metadata":{"source":"src/write.rs","assertion_line":1139,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n---'"}} +{"run_id":"1730154580-873153354","line":1161,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help","metadata":{"source":"src/write.rs","assertion_line":1161,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n---'"}} +{"run_id":"1730154580-873153354","line":1462,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_multi_lines","metadata":{"source":"src/write.rs","assertion_line":1462,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'"}} +{"run_id":"1730154580-873153354","line":1210,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help_note","metadata":{"source":"src/write.rs","assertion_line":1210,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154580-873153354","line":1300,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiple_labels_same_span","metadata":{"source":"src/write.rs","assertion_line":1300,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | | \n | `-------------- Have I mentioned that this is an apple?\n | | | \n | `-------------- No really, have I mentioned that?\n | | \n | `---- This is an orange\n | | \n | `---- Have I mentioned that this is an orange?\n | | \n | `---- No really, have I mentioned that?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | | |\n | `-------------- Have I mentioned that this is an apple?\n | | |\n | `-------------- No really, have I mentioned that?\n | |\n | `---- This is an orange\n | |\n | `---- Have I mentioned that this is an orange?\n | |\n | `---- No really, have I mentioned that?\n---'"}} +{"run_id":"1730154580-873153354","line":1332,"new":{"module_name":"ariadne__write__tests","snapshot_name":"note","metadata":{"source":"src/write.rs","assertion_line":1332,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154580-873153354","line":1436,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_single_lines","metadata":{"source":"src/write.rs","assertion_line":1436,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n---'"}} +{"run_id":"1730154580-873153354","line":1250,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiline_label","metadata":{"source":"src/write.rs","assertion_line":1250,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | ,-> apple\n : : \n 3 | |-> orange\n | | \n | `----------- illegal comparison\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | ,-> apple\n : :\n 3 | |-> orange\n | |\n | `----------- illegal comparison\n---'"}} +{"run_id":"1730154580-873153354","line":1185,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_note","metadata":{"source":"src/write.rs","assertion_line":1185,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154580-873153354","line":1072,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_column","metadata":{"source":"src/write.rs","assertion_line":1072,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154580-873153354","line":1412,"new":{"module_name":"ariadne__write__tests","snapshot_name":"single_note_single_line","metadata":{"source":"src/write.rs","assertion_line":1412,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note: No need to try, they can't be compared.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note: No need to try, they can't be compared.\n---'"}} +{"run_id":"1730154580-873153354","line":1000,"new":{"module_name":"ariadne__write__tests","snapshot_name":"two_labels_with_messages","metadata":{"source":"src/write.rs","assertion_line":1000,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n---'"}} +{"run_id":"1730154580-873153354","line":1273,"new":{"module_name":"ariadne__write__tests","snapshot_name":"partially_overlapping_labels","metadata":{"source":"src/write.rs","assertion_line":1273,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^ \n | `------------------- scheme\n | | \n | `----------- URL\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^\n | `------------------- scheme\n | |\n | `----------- URL\n---'"}} +{"run_id":"1730154580-873153354","line":1097,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_at_end_of_long_line","metadata":{"source":"src/write.rs","assertion_line":1097,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^ \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^\n | `---- This is an orange\n---'"}} +{"run_id":"1730154746-396557371","line":1139,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input","metadata":{"source":"src/write.rs","assertion_line":1139,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n---'"}} +{"run_id":"1730154746-396557371","line":1118,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_of_width_zero_at_end_of_line","metadata":{"source":"src/write.rs","assertion_line":1118,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | | \n | `- Unexpected end of file\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | apple ==\n | |\n | `- Unexpected end of file\n---'"}} +{"run_id":"1730154746-396557371","line":1185,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_note","metadata":{"source":"src/write.rs","assertion_line":1185,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154746-396557371","line":1161,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help","metadata":{"source":"src/write.rs","assertion_line":1161,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n---'"}} +{"run_id":"1730154746-396557371","line":1024,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_byte_chars","metadata":{"source":"src/write.rs","assertion_line":1024,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154746-396557371","line":1332,"new":{"module_name":"ariadne__write__tests","snapshot_name":"note","metadata":{"source":"src/write.rs","assertion_line":1332,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154746-396557371","line":964,"new":null,"old":null} +{"run_id":"1730154746-396557371","line":1097,"new":{"module_name":"ariadne__write__tests","snapshot_name":"label_at_end_of_long_line","metadata":{"source":"src/write.rs","assertion_line":1097,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^ \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == apple == orange\n | ^^|^^\n | `---- This is an orange\n---'"}} +{"run_id":"1730154746-396557371","line":980,"new":null,"old":null} +{"run_id":"1730154746-396557371","line":1048,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_label","metadata":{"source":"src/write.rs","assertion_line":1048,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:1]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154746-396557371","line":1462,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_multi_lines","metadata":{"source":"src/write.rs","assertion_line":1462,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n | It has no resemblance.\n---'"}} +{"run_id":"1730154746-396557371","line":1210,"new":{"module_name":"ariadne__write__tests","snapshot_name":"empty_input_help_note","metadata":{"source":"src/write.rs","assertion_line":1210,"expression":"msg"},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 | \n | | \n | `- No more fruit!\n | \n | Help: have you tried going to the farmer's market?\n | \n | Note: eat your greens!\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: unexpected end of file\n ,-[:1:1]\n |\n 1 |\n | |\n | `- No more fruit!\n |\n | Help: have you tried going to the farmer's market?\n |\n | Note: eat your greens!\n---'"}} +{"run_id":"1730154746-396557371","line":1436,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multi_notes_single_lines","metadata":{"source":"src/write.rs","assertion_line":1436,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note 1: No need to try, they can't be compared.\n | \n | Note 2: Yeah, really, please stop.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note 1: No need to try, they can't be compared.\n |\n | Note 2: Yeah, really, please stop.\n---'"}} +{"run_id":"1730154746-396557371","line":1358,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help","metadata":{"source":"src/write.rs","assertion_line":1358,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n---'"}} +{"run_id":"1730154746-396557371","line":1250,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiline_label","metadata":{"source":"src/write.rs","assertion_line":1250,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | ,-> apple\n : : \n 3 | |-> orange\n | | \n | `----------- illegal comparison\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | ,-> apple\n : :\n 3 | |-> orange\n | |\n | `----------- illegal comparison\n---'"}} +{"run_id":"1730154746-396557371","line":1385,"new":{"module_name":"ariadne__write__tests","snapshot_name":"help_and_note","metadata":{"source":"src/write.rs","assertion_line":1385,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n | \n | Help: have you tried peeling the orange?\n | \n | Note: stop trying ... this is a fruitless endeavor\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n |\n | Help: have you tried peeling the orange?\n |\n | Note: stop trying ... this is a fruitless endeavor\n---'"}} +{"run_id":"1730154746-396557371","line":1300,"new":{"module_name":"ariadne__write__tests","snapshot_name":"multiple_labels_same_span","metadata":{"source":"src/write.rs","assertion_line":1300,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | | \n | `-------------- Have I mentioned that this is an apple?\n | | | \n | `-------------- No really, have I mentioned that?\n | | \n | `---- This is an orange\n | | \n | `---- Have I mentioned that this is an orange?\n | | \n | `---- No really, have I mentioned that?\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | | |\n | `-------------- Have I mentioned that this is an apple?\n | | |\n | `-------------- No really, have I mentioned that?\n | |\n | `---- This is an orange\n | |\n | `---- Have I mentioned that this is an orange?\n | |\n | `---- No really, have I mentioned that?\n---'"}} +{"run_id":"1730154746-396557371","line":1072,"new":{"module_name":"ariadne__write__tests","snapshot_name":"byte_column","metadata":{"source":"src/write.rs","assertion_line":1072,"expression":"msg"},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an äpplë\n | | \n | `---- This is an örängë\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare äpplës with örängës\n ,-[:1:10]\n |\n 1 | äpplë == örängë;\n | ^^|^^ ^^^|^^\n | `-------------- This is an äpplë\n | |\n | `---- This is an örängë\n---'"}} +{"run_id":"1730154746-396557371","line":1412,"new":{"module_name":"ariadne__write__tests","snapshot_name":"single_note_single_line","metadata":{"source":"src/write.rs","assertion_line":1412,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^ \n | `--------- This is a strange comparison\n | \n | Note: No need to try, they can't be compared.\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^^^^^^|^^^^^^^\n | `--------- This is a strange comparison\n |\n | Note: No need to try, they can't be compared.\n---'"}} +{"run_id":"1730154746-396557371","line":1273,"new":{"module_name":"ariadne__write__tests","snapshot_name":"partially_overlapping_labels","metadata":{"source":"src/write.rs","assertion_line":1273,"expression":"msg"},"snapshot":"Error: \n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^ \n | `------------------- scheme\n | | \n | `----------- URL\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error:\n ,-[:1:1]\n |\n 1 | https://example.com/\n | ^^|^^^^^^^|^^^^^^^^^\n | `------------------- scheme\n | |\n | `----------- URL\n---'"}} +{"run_id":"1730154746-396557371","line":1000,"new":{"module_name":"ariadne__write__tests","snapshot_name":"two_labels_with_messages","metadata":{"source":"src/write.rs","assertion_line":1000,"expression":"msg"},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^ \n | `-------------- This is an apple\n | | \n | `---- This is an orange\n---'\n"},"old":{"module_name":"ariadne__write__tests","metadata":{},"snapshot":"Error: can't compare apples with oranges\n ,-[:1:1]\n |\n 1 | apple == orange;\n | ^^|^^ ^^^|^^\n | `-------------- This is an apple\n | |\n | `---- This is an orange\n---'"}} +{"run_id":"1730154821-476337710","line":1048,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1139,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1358,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1185,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1072,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1385,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1436,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1161,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1250,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1118,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1210,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1024,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1332,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1462,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1097,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1300,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":964,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1273,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1000,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":980,"new":null,"old":null} +{"run_id":"1730154821-476337710","line":1412,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1161,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1139,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1072,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1048,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1118,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1185,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1210,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1385,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1358,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1436,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1250,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1462,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1024,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1332,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1097,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1300,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":964,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1000,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1412,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":1273,"new":null,"old":null} +{"run_id":"1730154827-858030734","line":980,"new":null,"old":null} diff --git a/src/lib.rs b/src/lib.rs index 403017d..a4e9fbf 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -204,25 +204,21 @@ pub struct Report<'a, S: Span = Range> { msg: Option, notes: Vec, help: Option, - location: (::Owned, usize), + span: S, labels: Vec>, config: Config, } impl Report<'_, S> { /// Begin building a new [`Report`]. - pub fn build::Owned>>( - kind: ReportKind, - src_id: Id, - offset: usize, - ) -> ReportBuilder { + pub fn build(kind: ReportKind, span: S) -> ReportBuilder { ReportBuilder { kind, code: None, msg: None, notes: vec![], help: None, - location: (src_id.into(), offset), + span, labels: Vec::new(), config: Config::default(), } @@ -287,7 +283,7 @@ pub struct ReportBuilder<'a, S: Span> { msg: Option, notes: Vec, help: Option, - location: (::Owned, usize), + span: S, labels: Vec>, config: Config, } @@ -384,7 +380,7 @@ impl<'a, S: Span> ReportBuilder<'a, S> { msg: self.msg, notes: self.notes, help: self.help, - location: self.location, + span: self.span, labels: self.labels, config: self.config, } diff --git a/src/write.rs b/src/write.rs index 26db31e..76b398f 100644 --- a/src/write.rs +++ b/src/write.rs @@ -242,8 +242,8 @@ impl Report<'_, S> { let line_range = src.get_line_range(&char_span); // File name & reference - let location = if src_id == self.location.0.borrow() { - self.location.1 + let location = if src_id == self.span.source() { + self.span.start() } else { labels[0].char_span.start }; @@ -956,7 +956,7 @@ mod tests { #[test] fn one_message() { - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .finish() @@ -969,7 +969,7 @@ mod tests { #[test] fn two_labels_without_messages() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..5)) @@ -989,7 +989,7 @@ mod tests { #[test] fn two_labels_with_messages() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..5).with_message("This is an apple")) @@ -1013,7 +1013,7 @@ mod tests { #[test] fn multi_byte_chars() { let source = "äpplë == örängë;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii().with_index_type(IndexType::Char)) .with_message("can't compare äpplës with örängës") .with_label(Label::new(0..5).with_message("This is an äpplë")) @@ -1037,7 +1037,7 @@ mod tests { #[test] fn byte_label() { let source = "äpplë == örängë;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii().with_index_type(IndexType::Byte)) .with_message("can't compare äpplës with örängës") .with_label(Label::new(0..7).with_message("This is an äpplë")) @@ -1061,7 +1061,7 @@ mod tests { #[test] fn byte_column() { let source = "äpplë == örängë;"; - let msg = Report::>::build(ReportKind::Error, (), 11) + let msg = Report::build(ReportKind::Error, 11..11) .with_config(no_color_and_ascii().with_index_type(IndexType::Byte)) .with_message("can't compare äpplës with örängës") .with_label(Label::new(0..7).with_message("This is an äpplë")) @@ -1085,7 +1085,7 @@ mod tests { #[test] fn label_at_end_of_long_line() { let source = format!("{}orange", "apple == ".repeat(100)); - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label( @@ -1108,7 +1108,7 @@ mod tests { #[test] fn label_of_width_zero_at_end_of_line() { let source = "apple ==\n"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii().with_index_type(IndexType::Byte)) .with_message("unexpected end of file") .with_label(Label::new(9..9).with_message("Unexpected end of file")) @@ -1129,7 +1129,7 @@ mod tests { #[test] fn empty_input() { let source = ""; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("unexpected end of file") .with_label(Label::new(0..0).with_message("No more fruit!")) @@ -1150,7 +1150,7 @@ mod tests { #[test] fn empty_input_help() { let source = ""; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("unexpected end of file") .with_label(Label::new(0..0).with_message("No more fruit!")) @@ -1174,7 +1174,7 @@ mod tests { #[test] fn empty_input_note() { let source = ""; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("unexpected end of file") .with_label(Label::new(0..0).with_message("No more fruit!")) @@ -1198,7 +1198,7 @@ mod tests { #[test] fn empty_input_help_note() { let source = ""; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("unexpected end of file") .with_label(Label::new(0..0).with_message("No more fruit!")) @@ -1228,7 +1228,7 @@ mod tests { for i in 0..=source.len() { for j in i..=source.len() { - let _ = Report::>::build(ReportKind::Error, (), 0) + let _ = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii().with_index_type(IndexType::Byte)) .with_message("Label") .with_label(Label::new(i..j).with_message("Label")) @@ -1241,7 +1241,7 @@ mod tests { #[test] fn multiline_label() { let source = "apple\n==\norange"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_label(Label::new(0..source.len()).with_message("illegal comparison")) .finish() @@ -1263,7 +1263,7 @@ mod tests { #[test] fn partially_overlapping_labels() { let source = "https://example.com/"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_label(Label::new(0..source.len()).with_message("URL")) .with_label(Label::new(0..source.find(':').unwrap()).with_message("scheme")) @@ -1286,7 +1286,7 @@ mod tests { #[test] fn multiple_labels_same_span() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..5).with_message("This is an apple")) @@ -1321,7 +1321,7 @@ mod tests { #[test] fn note() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..5).with_message("This is an apple")) @@ -1347,7 +1347,7 @@ mod tests { #[test] fn help() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..5).with_message("This is an apple")) @@ -1373,7 +1373,7 @@ mod tests { #[test] fn help_and_note() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..5).with_message("This is an apple")) @@ -1402,13 +1402,13 @@ mod tests { #[test] fn single_note_single_line() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..15).with_message("This is a strange comparison")) .with_note("No need to try, they can't be compared.") .finish() - .write_to_string(Source::from(source)); + .write_to_string(Source::from(source)); assert_snapshot!(msg, @r###" Error: can't compare apples with oranges ,-[:1:1] @@ -1425,7 +1425,7 @@ mod tests { #[test] fn multi_notes_single_lines() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..15).with_message("This is a strange comparison")) @@ -1451,7 +1451,7 @@ mod tests { #[test] fn multi_notes_multi_lines() { let source = "apple == orange;"; - let msg = Report::>::build(ReportKind::Error, (), 0) + let msg = Report::build(ReportKind::Error, 0..0) .with_config(no_color_and_ascii()) .with_message("can't compare apples with oranges") .with_label(Label::new(0..15).with_message("This is a strange comparison"))