Are you able to run vite-plugin-angular through Intellij/Webstorm run configurations? #1380
-
After installing and configuring
This fails even with a bare describe('AppComponent', () => {
it('should render title', () => {
// do nothing, should just pass
});
}); If I comment out the Is this use case supported? Has anyone used it successfully? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
After looking at the example repo, I can see that the problem was the working directory I was using was wrong. It defaulted to the workspace root in an nx monorepo, but the working directory needs to be the same as the project directory. Using a run configuration template solved the issue. Create a <component name="ProjectRunConfigurationManager">
<configuration default="true" type="JavaScriptTestRunnerVitest">
<config value="$PROJECT_DIR$/apps/<YOUR_APP_NAME_HERE>/vite.config.mts" />
<node-interpreter value="project" />
<vitest-package value="$PROJECT_DIR$/node_modules/vitest" />
<working-dir value="$PROJECT_DIR$/apps/<YOUR_APP_NAME_HERE>" />
<envs />
<scope-kind value="ALL" />
<method v="2" />
</configuration>
</component> |
Beta Was this translation helpful? Give feedback.
After looking at the example repo, I can see that the problem was the working directory I was using was wrong. It defaulted to the workspace root in an nx monorepo, but the working directory needs to be the same as the project directory. Using a run configuration template solved the issue.
Create a
.run/Template Vitest.run.xml
file in your project directory.