summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorFilip Gospodinov <f@gospodinov.ch>2024-02-24 08:51:39 +0100
committerGitHub <noreply@github.com>2024-02-24 16:51:39 +0900
commit9cc8383fe930e0d6f21b17c9ebb2fdb55331b183 (patch)
tree9e4be5ee3b0cbc6293bb36e6d749e16bcd6dbb64 /test
parentb74cd026488853a3bc936600a03497cbd6587521 (diff)
downloadale-9cc8383fe930e0d6f21b17c9ebb2fdb55331b183.zip
Add full support for biome (#4705)
* Revert "Add biome support for javascript (#4701)" This reverts commit 8922478a83cd06bfe5b82eb45279649adc4ec046. * Add support for biome
Diffstat (limited to 'test')
-rw-r--r--test/fixers/test_biome_fixer_callback.vader30
-rw-r--r--test/linter/test_typescript_biome.vader14
-rw-r--r--test/test-files/biome/node_modules/.bin/biome0
-rw-r--r--test/test-files/biome/src/test.js0
4 files changed, 14 insertions, 30 deletions
diff --git a/test/fixers/test_biome_fixer_callback.vader b/test/fixers/test_biome_fixer_callback.vader
deleted file mode 100644
index 0cb4888e..00000000
--- a/test/fixers/test_biome_fixer_callback.vader
+++ /dev/null
@@ -1,30 +0,0 @@
-Before:
- call ale#assert#SetUpFixerTest('javascript', 'biome')
- runtime autoload/ale/handlers/biome.vim
- set filetype=javascript
-
-After:
- call ale#assert#TearDownFixerTest()
-
-Execute(The biome callback should return the correct default values):
- call ale#test#SetFilename('../test-files/biome/src/test.js')
-
- AssertFixer
- \ {
- \ 'read_temporary_file': 1,
- \ 'command': (has('win32') ? 'node.exe ' : '')
- \ . ale#Escape(ale#path#Simplify(g:dir . '/../test-files/biome/node_modules/.bin/biome'))
- \ . ' check --apply %t',
- \ }
-
-Execute(The biome callback should include custom biome options):
- let b:ale_javascript_biome_options = '--organize-imports-enabled=true'
- call ale#test#SetFilename('../test-files/biome/src/test.js')
-
- AssertFixer
- \ {
- \ 'read_temporary_file': 1,
- \ 'command': (has('win32') ? 'node.exe ' : '')
- \ . ale#Escape(ale#path#Simplify(g:dir . '/../test-files/biome/node_modules/.bin/biome'))
- \ . ' check --apply --organize-imports-enabled=true %t',
- \ }
diff --git a/test/linter/test_typescript_biome.vader b/test/linter/test_typescript_biome.vader
new file mode 100644
index 00000000..95b8fe82
--- /dev/null
+++ b/test/linter/test_typescript_biome.vader
@@ -0,0 +1,14 @@
+Before:
+ call ale#assert#SetUpLinterTest('typescript', 'biome')
+ call ale#test#SetFilename('test.ts')
+
+After:
+ call ale#assert#TearDownLinterTest()
+
+Execute(The default biome command should be correct):
+ AssertLinter 'biome', ale#Escape('biome') . ' lsp-proxy'
+
+Execute(The biome command should accept options):
+ let b:ale_biome_options = '--foobar'
+
+ AssertLinter 'biome', ale#Escape('biome') . ' lsp-proxy --foobar'
diff --git a/test/test-files/biome/node_modules/.bin/biome b/test/test-files/biome/node_modules/.bin/biome
deleted file mode 100644
index e69de29b..00000000
--- a/test/test-files/biome/node_modules/.bin/biome
+++ /dev/null
diff --git a/test/test-files/biome/src/test.js b/test/test-files/biome/src/test.js
deleted file mode 100644
index e69de29b..00000000
--- a/test/test-files/biome/src/test.js
+++ /dev/null