Commit Graph

5 Commits

Author SHA1 Message Date
Holger Detering
9b51f66960 Fix markdownlint output format (#5085)
* test: Add failing tests for markdownlint 0.47.0 output format

Add two new test cases to verify the markdownlint handler's ability to
parse output from version 0.47.0, which includes severity keywords
("error" or "warning"). These tests will fail with the current
implementation, demonstrating the need for a fix to handle the new
output format.

The tests specifically verify:
- Parsing of error severity keyword
- Parsing of warning severity keyword
- Correct mapping of severity to ALE type (E/W)

Backward compatibility with version 0.46.0 is already verified by
the existing ests.

* fix: Update markdownlint handler for version 0.47.0 output format

Update the markdownlint handler to support the new output format
introduced in version 0.47.0, which includes severity keywords ("error"
and "warning") after the column number.

Changes:
- Updated regex pattern to capture optional severity keyword
- Added type mapping logic (error → 'E', warning → 'W')
- Adjusted match indices for rule ID and description text
- Maintained backward compatibility with version 0.46.0

All tests now pass, including the new tests for 0.47.0 format.

* style: Fix vint linting errors in markdownlint handler

- Add blank line before if statement for better readability
- Replace `==#` with `is#` for case-sensitive comparison
2026-01-25 16:37:20 +09:00
w0rp
ae1d051504 #4454 Clean up more tests and code
* Remove some tests we no longer need
* Delete blocks of redundant code
* Compress some tests together to simplify them
* Remove a little code for ancient linter versions
* Escape more executables we didn't escape before
* Rename a deno option that didn't match our conventions
2023-09-16 22:23:30 +01:00
Sebastian Blask
fbfeae0587 Support markdownlint rules with multiple slashes 2020-07-31 11:15:13 +12:00
Sebastian Blask
7cada95683 Support markdownlint 0.19.0 and 0.22.0
Fixes #2965
2020-07-30 09:57:46 +12:00
Ty-Lucas Kelley
32091fb8ad add test for markdownlint hander 2018-03-03 19:32:32 -05:00