neotest-jest icon indicating copy to clipboard operation
neotest-jest copied to clipboard

Support template_string as test name

Open sassanh opened this issue 3 years ago • 2 comments

Tests written as test(`Some test`) are not supported (the test name is written in back ticks), it would be nice if we can support them.

sassanh avatar Nov 10 '22 13:11 sassanh

Additionally, it("has `backticks` in other quotes") doesn't work either

benlubas avatar Apr 07 '23 18:04 benlubas

I just encountered the same issue, just raised a PR to fix it (#112), seems to now work all okay locally.

With these changes should now detect tests like:

describe(`some describe`, () => {})
describe("`some describe` in a string", () => {})
it(`some it`, () => {})
it("`some it` in a string", () => {})

Shows up in the summary page like the below

some describe
`some describe` in a string
some it
`some it` in a string

conermurphy avatar Mar 28 '24 18:03 conermurphy