JavaScript: Add runnable tests (#12118)

https://github.com/zed-industries/zed/assets/62463826/2912c940-bd00-483d-9ce7-df1a2539560a


Release Notes:

- Added runnable tests for JavaScript & Typescript files.
- Added task to run selected javascript code.
This commit is contained in:
Remco Smits 2024-06-01 14:28:53 +02:00 committed by GitHub
parent 94c3101fb0
commit 29b5253a1d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 84 additions and 2 deletions

View file

@ -60,3 +60,14 @@
(accessibility_modifier)
]* @context
name: (_) @name) @item
; Add support for (node:test, bun:test and Jest) runnable
(call_expression
function: (_) @context
(#any-of? @context "it" "test" "describe")
arguments: (
arguments . (string
(string_fragment) @name
)
)
) @item