I'm exploring how to write unit tests for an existing LWC. It's clear that I can write assertions for public properties and DOM elements -- but is there a way to write assertions on other properties, like those marked with @track?
For example, the component has five @api properties and 40 @track properties. I'd like to write tests to assert the state on all of them (separately, of course).
Apex has the @TestVisible annotation. Is there something like that for LWC? Or another approach anyone can recommend?
Test Asynchronous DOM Updates
; where they mention you can create and render the element then change the properties which are marked as api or track. In case this isn't helpful, please share a more concrete example or scenario illustrating the problem.