From f861206d0b2e441bbd7aca53de311f79eeae24db Mon Sep 17 00:00:00 2001 From: cos Date: Thu, 3 Feb 2022 11:06:23 +0100 Subject: wip: Non-successful attempt at fixing tests Please see previous commit for the change requiring test updates. Tests fail due to mismatch between filename being set to '' and the proper filename. That's not a surprise, as the code path setting the value to anything but the actual filename has been disabled. It is unclear to me what '' is supposed to indicate, or how it should be used. Searching for the string in ale's codebase gives no matches outside of the rust handler and test cases. There are also failures due to finding the wrong span. Figuring out how to fix the ''/filename mismatch will likely fix that one too. --- test/handler/test_rust_handler.vader | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/test/handler/test_rust_handler.vader b/test/handler/test_rust_handler.vader index 845df2b5..a4c30828 100644 --- a/test/handler/test_rust_handler.vader +++ b/test/handler/test_rust_handler.vader @@ -7,6 +7,7 @@ Execute(The Rust handler should handle rustc output): \ 'lnum': 15, \ 'end_lnum': 15, \ 'type': 'E', + \ 'filename': '', \ 'col': 5, \ 'end_col': 7, \ 'text': 'expected one of `.`, `;`, `?`, `}`, or an operator, found `for`', @@ -14,6 +15,7 @@ Execute(The Rust handler should handle rustc output): \ { \ 'lnum': 13, \ 'end_lnum': 13, + \ 'filename': '', \ 'type': 'E', \ 'col': 7, \ 'end_col': 9, @@ -82,6 +84,7 @@ Execute(The Rust handler should handle cargo output): \ { \ 'lnum': 15, \ 'end_lnum': 15, + \ 'filename': 'src/playpen.rs', \ 'type': 'E', \ 'col': 5, \ 'end_col': 7, @@ -90,6 +93,7 @@ Execute(The Rust handler should handle cargo output): \ { \ 'lnum': 13, \ 'end_lnum': 13, + \ 'filename': 'src/playpen.rs', \ 'type': 'E', \ 'col': 7, \ 'end_col': 9, @@ -156,6 +160,7 @@ Execute(The Rust handler should should errors from expansion spans): \ { \ 'lnum': 4, \ 'end_lnum': 4, + \ 'filename': 'src/other.rs', \ 'type': 'E', \ 'col': 21, \ 'end_col': 22, @@ -206,6 +211,7 @@ Execute(The Rust handler should show detailed errors): \ { \ 'lnum': 4, \ 'end_lnum': 4, + \ 'filename': 'src/playpen.rs', \ 'type': 'E', \ 'col': 21, \ 'end_col': 22, @@ -255,6 +261,7 @@ Execute(The Rust handler should show detailed clippy errors with rendered field \ { \ 'lnum': 4, \ 'end_lnum': 4, + \ 'filename': 'src/playpen.rs', \ 'type': 'E', \ 'col': 21, \ 'end_col': 22, @@ -346,6 +353,7 @@ Execute(The Rust handler should remove secondary spans if set): \ { \ 'lnum': 1, \ 'end_lnum': 1, + \ 'filename': 'src/noerrors/mod.rs', \ 'type': 'E', \ 'end_col': 20, \ 'col': 1, @@ -354,6 +362,7 @@ Execute(The Rust handler should remove secondary spans if set): \ { \ 'lnum': 1, \ 'end_lnum': 1, + \ 'filename': 'src/noerrors/mod.rs', \ 'type': 'E', \ 'end_col': 45, \ 'col': 40, @@ -421,6 +430,7 @@ Execute(The Rust handler should remove secondary spans if set): \ { \ 'lnum': 1, \ 'end_lnum': 1, + \ 'filename': 'src/noerrors/mod.rs', \ 'type': 'E', \ 'end_col': 45, \ 'col': 40, -- cgit v1.2.3