vendredi 7 août 2020

Is there a way to test if Fontawesome icon layer is present?

I added a bell icon and then layered it with a counter. The counter will only appear if the counter variable is greater than 0. (I'm using ngIf to determine if the layer element is displayed) Is there a way in angular to test that the layered icon is present? I've tried many different approaches including this one:

How do I unit test if an element is visible when the *ngIf directive is used using Jasmine in Angular

but my test fails saying that it expects null to be true. It's not getting the html element and I can't seem to figure out why.

Aucun commentaire:

Enregistrer un commentaire