Excluding Tests

Hi All. I am building a service with Workers and I have my tests in a subfolder of each controller "{controller_name}/specs". I am concerned about them bloating the package when I deploy to production. Does anyone know the correct and preferred way to exclude them from the production build?
2 Replies
Hello, I’m Allie!
If the tests aren't imported by your Worker, then they will not be bundled wrangler doesn't just upload everything when you run deploy
dog1283
dog1283OP7mo ago
Ah perfect. Thanks for letting me know. Seems so obvious now you say it, but appreciate you taking the time.
Want results from more Discord servers?
Add your server