From 5aee6991a93702b4351605635a5c3c3d5d982cfd Mon Sep 17 00:00:00 2001 From: PavlovVasil Date: Wed, 21 Nov 2018 18:02:59 +0200 Subject: [PATCH] test(igxGrid): refactoring the custom sorting test #2734 --- .../src/lib/grids/grid/grid.sorting.spec.ts | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/projects/igniteui-angular/src/lib/grids/grid/grid.sorting.spec.ts b/projects/igniteui-angular/src/lib/grids/grid/grid.sorting.spec.ts index ad6cae90d03..b3411d4c347 100644 --- a/projects/igniteui-angular/src/lib/grids/grid/grid.sorting.spec.ts +++ b/projects/igniteui-angular/src/lib/grids/grid/grid.sorting.spec.ts @@ -23,7 +23,8 @@ describe('IgxGrid - Grid Sorting', () => { TestBed.configureTestingModule({ declarations: [ - GridDeclaredColumnsComponent + GridDeclaredColumnsComponent, + SortByParityComponent ], imports: [IgxGridModule.forRoot()] }) @@ -316,16 +317,8 @@ describe('IgxGrid - Grid Sorting', () => { fixture.detectChanges(); expect(sortingIcon.nativeElement.textContent.trim()).toEqual(SORTING_ICON_NONE_CONTENT); }); -}); -describe('IgxGrid - Grid Custom Sorting', () => { - let fixture; - let grid: IgxGridComponent; it(`Should allow sorting using a custom Sorting Strategy.`, () => { - TestBed.configureTestingModule({ - declarations: [SortByParityComponent], - imports: [IgxGridModule.forRoot()] - }).compileComponents(); fixture = TestBed.createComponent(SortByParityComponent); grid = fixture.componentInstance.grid; fixture.componentInstance.data.push( @@ -348,6 +341,7 @@ describe('IgxGrid - Grid Custom Sorting', () => { expect(isFirstHalfOdd).toEqual(true); expect(isSecondHalfEven).toEqual(true); }); + }); @Component({