Angular component testing can't find stylesheet to import #29962
Replies: 2 comments
-
Think i'm facing the same issue as you. I have an NX project and one of the libs is purely styles. Other libs import those styles. Libs project.json is configured with:
This means that I can shorten the import urls as below: Which helps when the libs are bundled and published. Everything works great, except Cypress, no matter what options i try to configure in Disabling the cypress component tests for now |
Beta Was this translation helpful? Give feedback.
-
I have the same problem. cypress.config.ts:
angular.json
Fehler
The Angular application works, only the Cypress component tests do not work. Is this a Cypress bug or a problem with the configuration? |
Beta Was this translation helpful? Give feedback.
-
I am using angular 18 and cypress 13.
When running my component testing specs, I cant find a way of properly loading the sass files I need.
For context, I am using angular material, and my tree setup looks something like this:
My cypress config is:
Component testing via Cypress works great, however, I am having problems loading the sass file that I need.
Basically, sass compiler is having issue when looking for the right path when using a
@use
rule.I get this error:
Which, by the way, doesn't happens when using angular, it only happens when using cypress component testing.
Any idea what might be the issue here?
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions