Hello. I was searching for testing resource for Jest/Playwright on Tanstack Start but I couldn't find any appropriate resource. Even the docs doesnt have any dedicated section on Testing Tanstack Start applications. Is there any update/possibility of introducing a dedicated testing documentation/resources for Tanstack Start? Thanks
#Jest and Playwright for Tanstack Start.
14 messages · Page 1 of 1 (latest)
cc @stuck cloak
As I recall we automatically install vitest. That's certainly my preferred test platform, not sure what @wicked shell's position is. I think you make a good callout about the need for docs on this. Can you file an issue on the router for a documentation update: https://github.com/TanStack/router/issues . That will help us prioritize it and give motivated folks an opportunity to add it as an OSS contribution.
we will most likely only support vitest when it comes to testing stuff like server functions
What about something like e2e testing?
I’m actually about to e2e with playwright
I guess I shouldn’t even try
But still I don’t see why it wouldn’t work, I’ll just go ahead try doing it and see if I can figure it out maybe write the docs
For sure. ✨
Will do ASAP.
Shouldn't even try? It should work just fine. You're just launching the server, and then using a browser to poke at the pages.
I agree with Jherr here. Its basically a browser environment testing the site.
The think its the subtle unease of breaking something and not finding any resources online regarding TS router or start.
Naturally, a dev who wants to learn Playwright (or Jest) would be more comfortable checking it out on a fresh Nextjs project, which has dozens of tutorials/blogs rather than Tanstack Start.
You are right
ps: I am actually working on a cool telemetry platform (using Nextjs) and I heavy rely on my exhaustive Jest test suites to keep it rigid. Honestly speaking, I am badly waiting for Tanstack Start to have good resources on Testing so that I can migrate.