Fix biome formatter (#4733)

* Fix biome formatter

Added escaped executable to the biome#Fix command

* Added fixer callback test
This commit is contained in:
David Dominguez 2024-03-02 02:05:47 -05:00 committed by GitHub
parent b01c0b23bb
commit 4d132b3ffa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 16 additions and 1 deletions

View File

@ -3,7 +3,7 @@ function! ale#fixers#biome#Fix(buffer) abort
let l:options = ale#Var(a:buffer, 'biome_options')
return {
\ 'command': '%e format'
\ 'command': ale#Escape(l:executable) . ' format'
\ . (!empty(l:options) ? ' ' . l:options : '')
\ . ' --stdin-file-path=%s',
\}

View File

@ -0,0 +1,15 @@
Before:
call ale#assert#SetUpFixerTest('typescript', 'biome')
After:
call ale#assert#TearDownFixerTest()
Execute(The default biome command should be correct):
call ale#test#SetFilename('../test-files/typescript/test.ts')
AssertFixer
\ {
\ 'command': ale#Escape('biome')
\ . ' format --stdin-file-path=%s'
\ }