ale/test/fixers/test_nimpretty_fixer_callback.vader

24 lines
633 B
Plaintext
Raw Normal View History

2019-11-09 08:34:15 +00:00
Before:
call ale#assert#SetUpFixerTest('nim', 'nimpretty')
After:
2019-11-14 14:50:16 +00:00
call ale#assert#TearDownFixerTest()
2019-11-09 08:34:15 +00:00
Execute(The nimpretty callback should return the correct default values):
AssertEqual
\ {
\ 'read_temporary_file': 1,
2019-11-14 14:50:16 +00:00
\ 'command': ale#Escape('nimpretty') . ' %t --maxLineLen:80'
2019-11-09 08:34:15 +00:00
\ },
\ ale#fixers#nimpretty#Fix(bufnr(''))
Execute(The nimpretty callback should include any additional options):
let g:ale_nim_nimpretty_options = '--some-option'
AssertEqual
\ {
\ 'read_temporary_file': 1,
2019-11-14 14:50:16 +00:00
\ 'command': ale#Escape('nimpretty') . ' %t --some-option'
2019-11-09 08:34:15 +00:00
\ },
\ ale#fixers#nimpretty#Fix(bufnr(''))