diff options
author | w0rp <devw0rp@gmail.com> | 2017-05-04 23:19:58 +0100 |
---|---|---|
committer | w0rp <devw0rp@gmail.com> | 2017-05-04 23:19:58 +0100 |
commit | 8e70dc14f2a51f0ef7acb64c3ef9850cb4f23e64 (patch) | |
tree | b123ebf4d721217c7a6dbb8fb6222c9855e64584 /test/handler | |
parent | 528355e2c6cf64fbc0d459a7a512a7823f90043d (diff) | |
download | ale-8e70dc14f2a51f0ef7acb64c3ef9850cb4f23e64.zip |
Fix #502 - Report undefined symbol errors better for javac
Diffstat (limited to 'test/handler')
-rw-r--r-- | test/handler/test_javac_handler.vader | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/test/handler/test_javac_handler.vader b/test/handler/test_javac_handler.vader new file mode 100644 index 00000000..2c0723b8 --- /dev/null +++ b/test/handler/test_javac_handler.vader @@ -0,0 +1,45 @@ +Before: + runtime ale_linters/java/javac.vim + +After: + call ale#linter#Reset() + +Execute(The javac handler should handle cannot find symbol errors): + AssertEqual + \ [ + \ { + \ 'lnum': 1, + \ 'text': 'error: some error', + \ 'type': 'E', + \ }, + \ { + \ 'lnum': 2, + \ 'text': 'error: cannot find symbol: BadName', + \ 'type': 'E', + \ }, + \ { + \ 'lnum': 34, + \ 'text': 'error: cannot find symbol: BadName2', + \ 'type': 'E', + \ }, + \ { + \ 'lnum': 37, + \ 'text': 'warning: some warning', + \ 'type': 'W', + \ }, + \ ], + \ ale_linters#java#javac#Handle(347, [ + \ '/tmp/vLPr4Q5/33/foo.java:1: error: some error', + \ '/tmp/vLPr4Q5/33/foo.java:2: error: cannot find symbol', + \ ' BadName foo() {', + \ ' ^', + \ ' symbol: class BadName', + \ ' location: class Bar', + \ '/tmp/vLPr4Q5/33/foo.java:34: error: cannot find symbol', + \ ' BadName2 foo() {', + \ ' ^', + \ ' symbol: class BadName2', + \ ' location: class Bar', + \ '/tmp/vLPr4Q5/33/foo.java:37: warning: some warning', + \ '4 errors', + \ ]) |