blob: 4bace0895963715b91aa0d3bfd8960a9384992ba (
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_sql_sqlformat_executable
Save g:ale_sql_sqlformat_options
After:
Restore
Execute(The sqlformat callback should return the correct default values):
AssertEqual
\ {
\ 'command': ale#Escape('sqlformat') . ' -'
\ },
\ ale#fixers#sqlformat#Fix(bufnr(''))
Execute(The sqlformat executable and options should be configurable):
let g:ale_sql_sqlformat_executable = '/path/to/sqlformat'
let g:ale_sql_sqlformat_options = '-a'
AssertEqual
\ {
\ 'command': ale#Escape('/path/to/sqlformat')
\ . ' -a -'
\ },
\ ale#fixers#sqlformat#Fix(bufnr(''))
|