File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
x-pack/legacy/plugins/maps/public/layers/fields Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -61,12 +61,20 @@ describe('supportsFieldMeta', () => {
6161
6262describe ( 'esAggFieldsFactory' , ( ) => {
6363 test ( 'Should only create top terms field when term field is not provided' , ( ) => {
64- const fields = esAggFieldsFactory ( { type : AGG_TYPE . TERMS } ) ;
64+ const fields = esAggFieldsFactory (
65+ { type : AGG_TYPE . TERMS } ,
66+ mockEsAggSource ,
67+ FIELD_ORIGIN . SOURCE
68+ ) ;
6569 expect ( fields . length ) . toBe ( 1 ) ;
6670 } ) ;
6771
6872 test ( 'Should create top terms and top terms percentage fields' , ( ) => {
69- const fields = esAggFieldsFactory ( { type : AGG_TYPE . TERMS , field : 'myField' } ) ;
73+ const fields = esAggFieldsFactory (
74+ { type : AGG_TYPE . TERMS , field : 'myField' } ,
75+ mockEsAggSource ,
76+ FIELD_ORIGIN . SOURCE
77+ ) ;
7078 expect ( fields . length ) . toBe ( 2 ) ;
7179 } ) ;
7280} ) ;
You can’t perform that action at this time.
0 commit comments