summaryrefslogtreecommitdiff
path: root/test/handler/test_nasm_handler.vader
diff options
context:
space:
mode:
authorØyvind Ingvaldsen <oyvind.ingvaldsen@gmail.com>2018-05-04 21:44:32 +0200
committerØyvind Ingvaldsen <oyvind.ingvaldsen@gmail.com>2018-05-04 21:44:32 +0200
commit27144eee8c5fbfc03578569067adeaf19c3d009d (patch)
tree0cdd7bc2318ca68054970ad4cdffb046af287543 /test/handler/test_nasm_handler.vader
parent726a768464d3e42869088599cf1bd049f7a751df (diff)
downloadale-27144eee8c5fbfc03578569067adeaf19c3d009d.zip
Added NASM linter
Added NASM linter (for nasm filetype).
Diffstat (limited to 'test/handler/test_nasm_handler.vader')
-rw-r--r--test/handler/test_nasm_handler.vader30
1 files changed, 30 insertions, 0 deletions
diff --git a/test/handler/test_nasm_handler.vader b/test/handler/test_nasm_handler.vader
new file mode 100644
index 00000000..95b8fefd
--- /dev/null
+++ b/test/handler/test_nasm_handler.vader
@@ -0,0 +1,30 @@
+Before:
+ runtime ale_linters/nasm/nasm.vim
+
+After:
+ call ale#linter#Reset()
+
+Execute(The nasm handler should parse GCC style output from nasm correctly):
+ AssertEqual
+ \ [
+ \ {
+ \ 'lnum': 2,
+ \ 'text': "label alone on a line without a colon might be in error",
+ \ 'type': 'W',
+ \ },
+ \ {
+ \ 'lnum': 4,
+ \ 'text': "invalid combination of opcode and operands",
+ \ 'type': 'E',
+ \ },
+ \ {
+ \ 'lnum': 7,
+ \ 'text': "unable to open include file `bar.asm'",
+ \ 'type': 'E',
+ \ },
+ \ ],
+ \ ale_linters#nasm#nasm#Handle(357, [
+ \ "tmp.asm:2: warning: label alone on a line without a colon might be in error",
+ \ "tmp.asm:4: error: invalid combination of opcode and operands",
+ \ "tmp.asm:7: fatal: unable to open include file `bar.asm'"
+ \ ])