diff options
author | w0rp <w0rp@users.noreply.github.com> | 2019-11-07 08:36:42 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-07 08:36:42 +0000 |
commit | 5eefe544ed3829b5f5d977c133361dc6ac907e05 (patch) | |
tree | 9c596f98f80fc12145d8957c0025819af00308d6 /test | |
parent | 2d9380d75c5c27a3241925d24ab3be8977a43207 (diff) | |
parent | e19b8c05cd8b0e74eb71d577ce6239bc71717dd9 (diff) | |
download | ale-5eefe544ed3829b5f5d977c133361dc6ac907e05.zip |
Merge pull request #2617 from robindar/master
Fix crystal-lang non file-tied message handling
Diffstat (limited to 'test')
-rw-r--r-- | test/handler/test_crystal_handler.vader | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/handler/test_crystal_handler.vader b/test/handler/test_crystal_handler.vader index a7b7f3ab..209632e9 100644 --- a/test/handler/test_crystal_handler.vader +++ b/test/handler/test_crystal_handler.vader @@ -16,3 +16,13 @@ Execute(The crystal handler should parse lines correctly and add the column if i \ ale_linters#crystal#crystal#Handle(255, [ \ '[{"file":"/tmp/test.cr","line":2,"column":1,"size":null,"message":"unexpected token: EOF"}]' \ ]) + +Execute(The crystal handler should not fail when a missing file is required): + AssertEqual + \ [ { 'lnum':1, 'col': 1, 'text': 'while requiring "./nonexistent.cr"' } ], + \ ale_linters#crystal#crystal#Handle(255, + \ json_encode([ + \ { "file":"/tmp/file.cr","line":1,"column":1,"size":0,"message":"while requiring \"./nonexistent.cr\"" }, + \ { "message": "can't find file './nonexistent.cr' relative to '/tmp'" }, + \ ]) + \ ) |