mirror of
https://github.com/dense-analysis/ale.git
synced 2025-12-30 16:14:30 +08:00
Detect and use CM files for smlnj (#884)
* Detect and use CM files for smlnj * Split into two checkers - one for CM projects - one for single SML files * Fix some typos * Fix error caught by writing tests We want to actually use `glob` to search in paths upwards from us. (Previously we were just searching in the current directory every time!) * Fix errors from former test run * Write tests for GetCmFile and GetExecutableSmlnj * Typo in 'smlnj/' fixture filenames
This commit is contained in:
@@ -1,6 +1,3 @@
|
||||
Before:
|
||||
runtime ale_linters/sml/smlnj.vim
|
||||
|
||||
Execute (Testing on EOF error):
|
||||
AssertEqual [
|
||||
\ {
|
||||
@@ -11,7 +8,7 @@ Execute (Testing on EOF error):
|
||||
\ 'text': 'Error: syntax error found at EOF',
|
||||
\ },
|
||||
\],
|
||||
\ ale_linters#sml#smlnj#Handle(42, [
|
||||
\ ale#handlers#sml#Handle(42, [
|
||||
\ "Standard ML of New Jersey v110.78 [built: Thu Jul 23 11:21:58 2015]",
|
||||
\ "[opening a.sml]",
|
||||
\ "a.sml:2.16 Error: syntax error found at EOF",
|
||||
@@ -35,7 +32,7 @@ Execute (Testing if the handler can handle multiple errors on the same line):
|
||||
\ 'text': 'Error: unbound variable or constructor: wow',
|
||||
\ },
|
||||
\],
|
||||
\ ale_linters#sml#smlnj#Handle(42, [
|
||||
\ ale#handlers#sml#Handle(42, [
|
||||
\ "Standard ML of New Jersey v110.78 [built: Thu Jul 23 11:21:58 2015]",
|
||||
\ "[opening test.sml]",
|
||||
\ "a.sml:1.6-1.10 Error: can't find function arguments in clause",
|
||||
@@ -61,7 +58,7 @@ Execute (Testing rarer errors):
|
||||
\ 'text': "Error: value type in structure doesn't match signature spec",
|
||||
\ },
|
||||
\],
|
||||
\ ale_linters#sml#smlnj#Handle(42, [
|
||||
\ ale#handlers#sml#Handle(42, [
|
||||
\ "Standard ML of New Jersey v110.78 [built: Thu Jul 23 11:21:58 2015]",
|
||||
\ "[opening test.sml]",
|
||||
\ "a.sml:5.19 Error: syntax error found at ID",
|
||||
@@ -80,7 +77,7 @@ Execute (Testing a warning):
|
||||
\ 'text': "Warning: match nonexhaustive",
|
||||
\ },
|
||||
\],
|
||||
\ ale_linters#sml#smlnj#Handle(42, [
|
||||
\ ale#handlers#sml#Handle(42, [
|
||||
\ "Standard ML of New Jersey v110.78 [built: Thu Jul 23 11:21:58 2015]",
|
||||
\ "[opening a.sml]",
|
||||
\ "a.sml:4.5-4.12 Warning: match nonexhaustive",
|
||||
|
||||
Reference in New Issue
Block a user