@@ -3038,9 +3038,39 @@ describe('IgxGrid - Advanced Filtering #grid - ', () => {
30383038 GridFunctions . clickAdvancedFilteringColumnSelect ( fix ) ;
30393039 fix . detectChanges ( ) ;
30403040 const dropdownValues = GridFunctions . getAdvancedFilteringSelectDropdownItems ( fix ) . map ( ( x : any ) => x . innerText ) ;
3041- const expectedValues = [ 'ID' , 'ProductName' , 'Downloads' , 'Released' , 'ReleaseDate' , 'Another Field' ] ;
3041+ const expectedValues = [ 'ID' , 'ProductName' , 'Downloads' , 'Released' , 'ReleaseDate' , 'Another Field' , 'DateTimeCreated' ] ;
30423042 expect ( expectedValues ) . toEqual ( dropdownValues ) ;
30433043 } ) ) ;
3044+
3045+ it ( 'Should correctly focus the search value input when editing the filtering expression' , fakeAsync ( ( ) => {
3046+ // Open dialog through API.
3047+ grid . openAdvancedFilteringDialog ( ) ;
3048+ fix . detectChanges ( ) ;
3049+
3050+ //Create dateTime filtering expression
3051+ const tree = new FilteringExpressionsTree ( FilteringLogic . And ) ;
3052+ tree . filteringOperands . push ( {
3053+ fieldName : 'DateTimeCreated' , searchVal : '11/11/2000 10:11:11 AM' , condition : IgxStringFilteringOperand . instance ( ) . condition ( 'equals' )
3054+ } ) ;
3055+
3056+ grid . advancedFilteringExpressionsTree = tree ;
3057+ fix . detectChanges ( ) ;
3058+
3059+ // Hover the last visible expression chip
3060+ const expressionItem = fix . nativeElement . querySelectorAll ( `.${ ADVANCED_FILTERING_EXPRESSION_ITEM_CLASS } ` ) [ 0 ] ;
3061+ expressionItem . dispatchEvent ( new MouseEvent ( 'mouseenter' ) ) ;
3062+ tick ( ) ;
3063+ fix . detectChanges ( ) ;
3064+
3065+ // Click the edit icon to enter edit mode of the expression.
3066+ GridFunctions . clickAdvancedFilteringTreeExpressionChipEditIcon ( fix , [ 0 ] ) ;
3067+ tick ( ) ;
3068+ fix . detectChanges ( ) ;
3069+
3070+ //Check for the active element
3071+ let searchValueInput = GridFunctions . getAdvancedFilteringValueInput ( fix ) . querySelector ( 'input' ) ;
3072+ expect ( document . activeElement ) . toBe ( searchValueInput , 'The input should be the active element.' ) ;
3073+ } ) ) ;
30443074 } ) ;
30453075
30463076 describe ( 'External - ' , ( ) => {
0 commit comments