Picked a sample React app on StackBlitz. How does one run unit tests?
I see many people creating an app with tests, what's the purpose if those cannot be executed?
I guess you'd need a node.js project setup in order to run those?
Picked a sample React app on StackBlitz. How does one run unit tests?
I see many people creating an app with tests, what's the purpose if those cannot be executed?
I guess you'd need a node.js project setup in order to run those?
Copyright © 2021 Jogjafile Inc.
From Available environments documentation:
From Can I run unit tests in StackBlitz? documentation:
Your project uses the
EngineBlockenvironment, you need to use theWebContainersenvironment.You can see this example, please note there is a
.stackblitzrcconfiguration file to specify the start command. Thenpm run testscript will be run after installing the dependencies.