@@ -895,6 +895,21 @@ describe('IgxSimpleCombo', () => {
895895 expect ( combo . selection . length ) . toEqual ( 0 ) ;
896896 } ) ;
897897
898+ it ( 'should not clear selection on tab/blur after filtering and selecting a value' , ( ) => {
899+ UIInteractions . simulateTyping ( 'con' , input ) ;
900+ expect ( combo . comboInput . value ) . toEqual ( 'con' ) ;
901+ fixture . detectChanges ( ) ;
902+
903+ UIInteractions . triggerKeyDownEvtUponElem ( 'Enter' , input . nativeElement ) ;
904+ expect ( combo . selection . length ) . toEqual ( 1 ) ;
905+ expect ( combo . value ) . toEqual ( 'Wisconsin' ) ;
906+
907+ UIInteractions . triggerEventHandlerKeyDown ( 'Tab' , input ) ;
908+ fixture . detectChanges ( ) ;
909+ expect ( combo . selection . length ) . toEqual ( 1 ) ;
910+ expect ( combo . value ) . toEqual ( 'Wisconsin' ) ;
911+ } ) ;
912+
898913 it ( 'should display the AddItem button when allowCustomValues is true and there is a partial match' , fakeAsync ( ( ) => {
899914 fixture . componentInstance . allowCustomValues = true ;
900915 fixture . detectChanges ( ) ;
@@ -1118,7 +1133,7 @@ describe('IgxSimpleCombo', () => {
11181133
11191134 item1 . triggerEventHandler ( 'click' , UIInteractions . getMouseEvent ( 'click' ) ) ;
11201135 fixture . detectChanges ( ) ;
1121- expect ( combo . value ) . toBe ( null ) ;
1136+ expect ( combo . value ) . toBe ( '' ) ;
11221137
11231138 combo . open ( ) ;
11241139 fixture . detectChanges ( ) ;
@@ -1145,7 +1160,7 @@ describe('IgxSimpleCombo', () => {
11451160
11461161 item5 . triggerEventHandler ( 'click' , UIInteractions . getMouseEvent ( 'click' ) ) ;
11471162 fixture . detectChanges ( ) ;
1148- expect ( combo . value ) . toBe ( undefined ) ;
1163+ expect ( combo . value ) . toBe ( '' ) ;
11491164 } ) ;
11501165
11511166 it ( 'should select falsy values except "undefined"' , ( ) => {
0 commit comments