summaryrefslogtreecommitdiff
path: root/test/linter/test_jsonnetfmt.vader
blob: d070cd9ff11598c897c0f552b5933e7f8560ac5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Before:
  call ale#assert#SetUpLinterTest('jsonnet', 'jsonnetfmt')
  call ale#test#SetFilename('../jsonnet_files/testfile.jsonnet')

After:
  Restore

  call ale#assert#TearDownLinterTest()

Execute(The default jsonnetfmt command should be correct):
  AssertLinter 'jsonnetfmt',
  \ ale#Escape('jsonnetfmt') . ' %t'

Execute(jsonnetfmt command and options should be customizable):
  let g:ale_jsonnet_jsonnetfmt_executable = 'jsonnet'
  let g:ale_jsonnet_jsonnetfmt_options = 'fmt'

  AssertLinter 'jsonnet',
  \ ale#Escape('jsonnet') . ' fmt %t'