mirror of
https://github.com/dense-analysis/ale.git
synced 2025-12-06 12:44:23 +08:00
add rego support (#4199)
* add opa fmt fixer for rego files * add opa linter * add basic tests for linter and fixer * add cspell to the docs
This commit is contained in:
committed by
GitHub
parent
5479b58660
commit
75d2413425
16
test/linter/test_rego_opacheck.vader
Normal file
16
test/linter/test_rego_opacheck.vader
Normal file
@@ -0,0 +1,16 @@
|
||||
|
||||
" Based upon :help ale-development
|
||||
Before:
|
||||
call ale#assert#SetUpLinterTest('rego', 'opacheck')
|
||||
|
||||
After:
|
||||
call ale#assert#TearDownLinterTest()
|
||||
|
||||
Execute(The default command should be correct):
|
||||
AssertLinter 'opa',
|
||||
\ ale#Escape('opa') . ' check %s --format json '
|
||||
|
||||
Execute(The default command should be overriden):
|
||||
let b:ale_rego_opacheck_executable = '/bin/other/opa'
|
||||
AssertLinter '/bin/other/opa',
|
||||
\ ale#Escape('/bin/other/opa') . ' check %s --format json '
|
||||
Reference in New Issue
Block a user