mirror of
https://github.com/dense-analysis/ale.git
synced 2026-01-04 18:43:30 +08:00
Simplify the sandbox check, to save on execution time
This commit is contained in:
@@ -27,12 +27,18 @@ After:
|
||||
delfunction TestCallback
|
||||
call ale#linter#Reset()
|
||||
let g:ale_buffer_info = {}
|
||||
unlet! b:in_sandbox
|
||||
|
||||
Given foobar (Some imaginary filetype):
|
||||
foo
|
||||
bar
|
||||
baz
|
||||
|
||||
Execute(ale#util#InSandbox should return 1 when in a sandbox):
|
||||
sandbox let b:in_sandbox = ale#util#InSandbox()
|
||||
|
||||
Assert b:in_sandbox, 'ale#util#InSandbox() returned 0 for a sandbox command'
|
||||
|
||||
Execute(ALE shouldn't blow up when run from a sandbox):
|
||||
AssertEqual 'foobar', &filetype
|
||||
|
||||
|
||||
Reference in New Issue
Block a user