Skip to content

Commit

Permalink
test: fix some fancy tests after NamedSource change
Browse files Browse the repository at this point in the history
  • Loading branch information
zkat committed Feb 4, 2024
1 parent 1fa7f52 commit 3747fcc
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions tests/graphical.rs
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ fn multiple_spans_multiline() {
#[diagnostic(severity(Error))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<&'static str>,
#[label("big")]
big: SourceSpan,
#[label("small")]
Expand Down Expand Up @@ -824,7 +824,7 @@ fn multiline_label() -> Result<(), MietteError> {
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label("this bit here\nand\nthis\ntoo")]
highlight: SourceSpan,
}
Expand Down Expand Up @@ -864,7 +864,7 @@ fn multiple_multi_line_labels() -> Result<(), MietteError> {
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label = "x\ny"]
highlight1: SourceSpan,
#[label = "z\nw"]
Expand Down Expand Up @@ -1040,7 +1040,7 @@ fn multiline_highlight_multiline_label() -> Result<(), MietteError> {
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label = "these two lines\nare the problem"]
highlight: SourceSpan,
}
Expand Down Expand Up @@ -1620,7 +1620,7 @@ fn primary_label() {
#[error("oops!")]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<&'static str>,
#[label]
first_label: SourceSpan,
#[label(primary, "nope")]
Expand Down Expand Up @@ -1656,7 +1656,7 @@ fn single_line_with_wide_char_unaligned_span_start() -> Result<(), MietteError>
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label("this bit here")]
highlight: SourceSpan,
}
Expand Down Expand Up @@ -1693,7 +1693,7 @@ fn single_line_with_wide_char_unaligned_span_end() -> Result<(), MietteError> {
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label("this bit here")]
highlight: SourceSpan,
}
Expand Down Expand Up @@ -1730,7 +1730,7 @@ fn single_line_with_wide_char_unaligned_span_empty() -> Result<(), MietteError>
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label("this bit here")]
highlight: SourceSpan,
}
Expand Down Expand Up @@ -1769,7 +1769,7 @@ fn syntax_highlighter() {
#[diagnostic()]
pub struct Test {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label("this is a label")]
src_span: SourceSpan,
}
Expand Down Expand Up @@ -1814,7 +1814,7 @@ fn syntax_highlighter_on_real_file() {
#[diagnostic()]
pub struct Test {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label("this is a label")]
src_span: SourceSpan,
}
Expand Down Expand Up @@ -1864,7 +1864,7 @@ fn triple_adjacent_highlight() -> Result<(), MietteError> {
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label = "this bit here"]
highlight1: SourceSpan,
#[label = "also this bit"]
Expand Down Expand Up @@ -1913,7 +1913,7 @@ fn non_adjacent_highlight() -> Result<(), MietteError> {
#[diagnostic(code(oops::my::bad), help("try doing it better next time?"))]
struct MyBad {
#[source_code]
src: NamedSource,
src: NamedSource<String>,
#[label = "this bit here"]
highlight1: SourceSpan,
#[label = "also this bit"]
Expand Down

0 comments on commit 3747fcc

Please sign in to comment.