fix(module:segmented): correctly render with-icon & icon-only - #9367
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #9367 +/- ##
==========================================
- Coverage 92.25% 92.21% -0.04%
==========================================
Files 561 561
Lines 19680 19684 +4
Branches 3015 3015
==========================================
- Hits 18156 18152 -4
- Misses 1192 1200 +8
Partials 332 332 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Just a question, the test added previously maybe need to be adapted ?
@HyperLife1119 WDYT :) ?
|
Yes, I'll add a more complete test later. @Nicoss54 |
41fc8f4 to
f34f1e7
Compare
f34f1e7 to
586a58c
Compare
| fixture.detectChanges(); | ||
| }); | ||
|
|
||
| it('should render an icon element and a text node with a wrapper element if the item is label-with-icon', () => { |
There was a problem hiding this comment.
question: do we not need to inject the provideNzIconsTesting in the TestBed.configureTestingModule() providers options to avoid error on rendering icon ?
There was a problem hiding this comment.
question: do we not need to inject the
provideNzIconsTestingin theTestBed.configureTestingModule()providers options to avoid error on rendering icon ?
In theory, any icon used in a test should use provideNzIconsTesting, which registers all icons. However, zorro registers some built-in icons by default (see /components/icon/icons.ts). If I only use these built-in icons, I can avoid using provideNzIconsTesting :)
There was a problem hiding this comment.
Ohhhh okkey i missed this information ! Thanks a lot 😀
PR Checklist
Please check if your PR fulfills the following requirements:
PR Type
What kind of change does this PR introduce?
What is the current behavior?
Issue Number: N/A
What is the new behavior?
Does this PR introduce a breaking change?
Other information