Skip to content

Commit c5a6481

Browse files
refactor(simple-combo-tests): remove fakeAsync
1 parent e5d5e6b commit c5a6481

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

projects/igniteui-angular/src/lib/simple-combo/simple-combo.component.spec.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ describe('IgxSimpleCombo', () => {
8080
get: mockNgControl
8181
});
8282
mockSelection.get.and.returnValue(new Set([]));
83-
const mockIconService = new IgxIconService(null, null, null);
83+
const mockIconService = new IgxIconService(null, null, null, null);
8484
const platformUtil = new PlatformUtil('browser');
8585
it('should properly call dropdown methods on toggle', () => {
8686
combo = new IgxSimpleComboComponent(elementRef, mockCdr, mockSelection as any, mockComboService,
@@ -915,7 +915,7 @@ describe('IgxSimpleCombo', () => {
915915
expect(document.activeElement).toEqual(addItemButton.nativeElement);
916916
}));
917917

918-
it('should close when an item is clicked on', fakeAsync(() => {
918+
it('should close when an item is clicked on', () => {
919919
spyOn(combo, 'close').and.callThrough();
920920
combo.open();
921921
fixture.detectChanges();
@@ -926,9 +926,9 @@ describe('IgxSimpleCombo', () => {
926926
fixture.detectChanges();
927927

928928
expect(combo.close).toHaveBeenCalledTimes(1);
929-
}));
929+
});
930930

931-
it('should scroll to top when opened and there is no selection', fakeAsync(() => {
931+
it('should scroll to top when opened and there is no selection', () => {
932932
combo.deselect();
933933
fixture.detectChanges();
934934

@@ -943,7 +943,7 @@ describe('IgxSimpleCombo', () => {
943943

944944
expect(combo.onClick).toHaveBeenCalledTimes(1);
945945
expect((combo as any).virtDir.scrollTo).toHaveBeenCalledWith(0);
946-
}));
946+
});
947947

948948
it('should close the dropdown with Alt + ArrowUp', fakeAsync(() => {
949949
combo.open();
@@ -961,7 +961,7 @@ describe('IgxSimpleCombo', () => {
961961
expect(combo.close).toHaveBeenCalledTimes(1);
962962
}));
963963

964-
it('should select the first filtered item with Enter', fakeAsync(() => {
964+
it('should select the first filtered item with Enter', () => {
965965
UIInteractions.setInputElementValue(input, 'con', fixture);
966966
expect(combo.comboInput.value).toEqual('con');
967967

@@ -972,9 +972,9 @@ describe('IgxSimpleCombo', () => {
972972
UIInteractions.triggerKeyDownEvtUponElem('Enter', input.nativeElement);
973973
fixture.detectChanges();
974974
expect(input.nativeElement.value).toEqual('Wisconsin');
975-
}));
975+
});
976976

977-
it('should clear selection when all text in input is removed by Backspace and Delete', fakeAsync(() => {
977+
it('should clear selection when all text in input is removed by Backspace and Delete', () => {
978978
combo.select('Wisconsin');
979979
fixture.detectChanges();
980980

@@ -997,7 +997,7 @@ describe('IgxSimpleCombo', () => {
997997
UIInteractions.triggerEventHandlerKeyDown('Backspace', input);
998998
fixture.detectChanges();
999999
expect(combo.selection.length).toEqual(0);
1000-
}));
1000+
});
10011001

10021002
it('should close the dropdown (if opened) when tabbing outside of the input', () => {
10031003
combo.open();

0 commit comments

Comments
 (0)