blob: 880ac83eddf2f3288221bce3fcaf1acb96d97bf4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
Before:
Save g:ale_nix_nixfmt_executable
Save g:ale_nix_nixfmt_options
After:
Restore
Execute(The nixfmt callback should return the correct default values):
AssertEqual
\ {
\ 'command': ale#Escape('nixfmt')
\ },
\ ale#fixers#nixfmt#Fix(bufnr(''))
Execute(The nixfmt executable and options should be configurable):
let g:ale_nix_nixfmt_executable = '/path/to/nixfmt'
let g:ale_nix_nixfmt_options = '--help'
AssertEqual
\ {
\ 'command': ale#Escape('/path/to/nixfmt')
\ . ' --help',
\ },
\ ale#fixers#nixfmt#Fix(bufnr(''))
|