Skip to content

Commit 6e829f8

Browse files
authoredFeb 7, 2024··
fix(tests): revert test-breaking changes of e5c7ae4 (#339)
The commit e5c7ae4 seemed to (potentially erronously?) remove a number of spaces following the left `|` bar of some graphical report handler tests. That change had no effect on the `syntax_highlighter_on_real_file()` test, presumably because the trailing whitespace is removed by `strip_ansi_escapes::strip_str()`, but it did break the `triple_adjacent_highlight()` and `non_adjacent_hightlight()` tests. Restoring the spaces removed in e5c7ae4 fixes the failing tests on main. * fix(ci): move from minimal-versions to direct-minimal-versions
1 parent ecb0102 commit 6e829f8

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed
 

‎.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,4 +79,4 @@ jobs:
7979
with:
8080
toolchain: nightly
8181
- name: Run minimal version build
82-
run: cargo build -Z minimal-versions --features fancy,no-format-args-capture
82+
run: cargo build -Z direct-minimal-versions --features fancy,no-format-args-capture

‎Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ futures = { version = "0.3", default-features = false }
3636
indenter = "0.3.3"
3737
rustversion = "1.0"
3838
trybuild = { version = "1.0.89", features = ["diff"] }
39-
syn = { version = "2.0", features = ["full"] }
39+
syn = { version = "2.0.48", features = ["full"] }
4040
regex = "1.10"
4141
lazy_static = "1.4"
4242

‎miette-derive/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@ proc-macro = true
1212

1313
[dependencies]
1414
proc-macro2 = "1.0.78"
15-
quote = "1.0"
15+
quote = "1.0.35"
1616
syn = "2.0.48"

‎tests/graphical.rs

+8-8
Original file line numberDiff line numberDiff line change
@@ -1864,11 +1864,11 @@ fn syntax_highlighter_on_real_file() {
18641864
let expected = format!(
18651865
r#" × This is an error
18661866
╭─[{filename}:{l2}:{CO}]
1867-
{l1} │
1867+
{l1} │
18681868
{l2} │ let (filename, line) = (file!(), line!() as usize);
18691869
· ─────────────┬─────────────
18701870
· ╰── this is a label
1871-
{l3} │
1871+
{l3} │
18721872
╰────
18731873
"#,
18741874
l1 = line - 1,
@@ -1911,13 +1911,13 @@ fn triple_adjacent_highlight() -> Result<(), MietteError> {
19111911
1 │ source
19121912
· ───┬──
19131913
· ╰── this bit here
1914-
2 │
1915-
3 │
1914+
2 │
1915+
3 │
19161916
4 │ text
19171917
· ──┬─
19181918
· ╰── also this bit
1919-
5 │
1920-
6 │
1919+
5 │
1920+
6 │
19211921
7 │ here
19221922
· ──┬─
19231923
· ╰── finally we got
@@ -1957,10 +1957,10 @@ fn non_adjacent_highlight() -> Result<(), MietteError> {
19571957
1 │ source
19581958
· ───┬──
19591959
· ╰── this bit here
1960-
2 │
1960+
2 │
19611961
╰────
19621962
╭─[bad_file.rs:5:3]
1963-
4 │
1963+
4 │
19641964
5 │ text here
19651965
· ──┬─
19661966
· ╰── also this bit

0 commit comments

Comments
 (0)
Please sign in to comment.