How to compile Cypress TypeScript without running tests

Viewed 363

Our project uses Cypress to run e2e tests. We have 5 different suites that run twice a day, at different times.

My problem is that we can currently introduce compilation problems and we won't find out until we run the e2e tests, which is after we've committed. I would like to be able to build my Cypress TypeScript to make sure it doesn't have any type errors so that we can prevent pushing to main.

I have not been able to find some configuration that would compile all the TypeScript but would not run the tests. Has anyone been able to achieve such configuration?

1 Answers

It turns out to be as simple as @RazLuvaton mentioned. Just run tsc on your own. You can even pass the --no-emit if, like me, you just want check types.

Related