test: add filterable test for indirect types

This commit is contained in:
Wieland Schöbl
2021-07-05 17:06:04 +02:00
parent 90fc78c142
commit 99c698bd16

View File

@@ -17,6 +17,8 @@ import {ThingType} from './types';
import {MapAggTestOptions} from '../../MapAggTestOptions'; import {MapAggTestOptions} from '../../MapAggTestOptions';
import {ElasticsearchDataType} from '../../../../src/mappings/definitions/typemap'; import {ElasticsearchDataType} from '../../../../src/mappings/definitions/typemap';
export type FilterableEnumType = 'a' | 'b' | 'c';
/** /**
* @indexable * @indexable
*/ */
@@ -38,6 +40,11 @@ export interface FilterableTag {
*/ */
baz: 'some literal' baz: 'some literal'
/**
* @filterable
*/
buz: FilterableEnumType
type: ThingType.FilterableTag type: ThingType.FilterableTag
} }
@@ -68,6 +75,14 @@ export const filterableTagTest: MapAggTestOptions = {
type: ElasticsearchDataType.keyword type: ElasticsearchDataType.keyword
} }
} }
},
buz: {
type: ElasticsearchDataType.keyword,
fields: {
raw: {
type: ElasticsearchDataType.keyword
}
}
} }
} }
} }