Skip to content

Commit 7923d7d

Browse files
committed
test(*): apply control flow suggestions
1 parent 7605893 commit 7923d7d

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.spec.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ describe('igxGridEditingActions #grid ', () => {
390390
template: `
391391
<igx-grid #grid [data]="data" [width]="'800px'" [height]="'500px'"
392392
[rowEditable]="true" [primaryKey]="'ID'">
393-
@for (c of columns; track c) {
393+
@for (c of columns; track c.field) {
394394
<igx-column [sortable]="true" [field]="c.field" [header]="c.field"
395395
[width]="c.width" [pinned]='c.pinned' [hidden]='c.hidden'>
396396
</igx-column>
@@ -469,7 +469,7 @@ class IgxActionStripTestingComponent implements OnInit {
469469
template: `
470470
<igx-grid #grid [data]="data" [width]="'800px'" [height]="'500px'"
471471
[rowEditable]="true" [primaryKey]="'ID'">
472-
@for (c of columns; track c) {
472+
@for (c of columns; track c.field) {
473473
<igx-column [sortable]="true" [field]="c.field" [header]="c.field"
474474
[width]="c.width" [pinned]='c.pinned' [hidden]='c.hidden'>
475475
</igx-column>
@@ -491,7 +491,7 @@ class IgxActionStripPinEditComponent extends IgxActionStripTestingComponent {
491491
template: `
492492
<igx-grid #grid [data]="data" [width]="'800px'" [height]="'500px'"
493493
[rowEditable]="true" [primaryKey]="'ID'">
494-
@for (c of columns; track c) {
494+
@for (c of columns; track c.field) {
495495
<igx-column [sortable]="true" [field]="c.field" [header]="c.field"
496496
[width]="c.width" [pinned]='c.pinned' [hidden]='c.hidden'>
497497
</igx-column>
@@ -512,7 +512,7 @@ class IgxActionStripEditMenuComponent extends IgxActionStripTestingComponent {
512512
template: `
513513
<igx-grid #grid [data]="dataOneRow" [width]="'800px'" [height]="'500px'"
514514
[rowEditable]="true" [primaryKey]="'ID'">
515-
@for (c of columns; track c) {
515+
@for (c of columns; track c.field) {
516516
<igx-column [sortable]="true" [field]="c.field" [header]="c.field"
517517
[width]="c.width" [pinned]='c.pinned' [hidden]='c.hidden'>
518518
</igx-column>
@@ -534,7 +534,7 @@ class IgxActionStripOneRowComponent extends IgxActionStripTestingComponent {
534534
template: `
535535
<igx-grid #grid [data]="dataOneRow" [width]="'800px'" [height]="'500px'"
536536
[rowEditable]="true" [primaryKey]="'ID'">
537-
@for (c of columns; track c) {
537+
@for (c of columns; track c.field) {
538538
<igx-column [sortable]="true" [field]="c.field" [header]="c.field"
539539
[width]="c.width" [pinned]='c.pinned' [hidden]='c.hidden'>
540540
</igx-column>

projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ describe('igxGridPinningActions #grid ', () => {
102102
template: `
103103
<igx-grid #grid [data]="data" [width]="'800px'" [height]="'500px'"
104104
[rowEditable]="true" [primaryKey]="'ID'">
105-
@for (c of columns; track c) {
105+
@for (c of columns; track c.field) {
106106
<igx-column [sortable]="true" [field]="c.field" [header]="c.field"
107107
[width]="c.width" [pinned]='c.pinned' [hidden]='c.hidden'>
108108
</igx-column>
@@ -176,7 +176,7 @@ class IgxActionStripTestingComponent implements OnInit {
176176
template: `
177177
<igx-grid #grid [data]="data" [width]="'800px'" [height]="'500px'"
178178
[rowEditable]="true" [primaryKey]="'ID'">
179-
@for (c of columns; track c) {
179+
@for (c of columns; track c.field) {
180180
<igx-column [sortable]="true" [field]="c.field" [header]="c.field"
181181
[width]="c.width" [pinned]='c.pinned' [hidden]='c.hidden'>
182182
</igx-column>

projects/igniteui-angular/src/lib/buttonGroup/buttongroup.component.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,7 @@ class ButtonGroupWithSelectedButtonComponent {
584584
@Component({
585585
template: `
586586
<igx-buttongroup>
587-
@for (item of items; track item) {
587+
@for (item of items; track item.key) {
588588
<button igxButton [selected]="item.key === selectedValue">{{item.value}}</button>
589589
}
590590
</igx-buttongroup>

0 commit comments

Comments
 (0)