import { getListTemplate } from './get_list_template' ; jest . mock ( './list_mappings.json' , ( ) => ( { listMappings : { } , } ) ) ; describe ( 'get_list_template' , ( ) => { beforeEach ( ( ) => { jest . clearAllMocks ( ) ; } ) ; afterEach ( ( ) => { jest . clearAllMocks ( ) ; } ) ; test ( 'it returns a list template with the string filled in' , async ( ) => { const template = getListTemplate ( 'some_index' ) ; expect ( template ) . toEqual ( { index_patterns : [ 'some_index-*' ] , mappings : { listMappings : { } } , settings : { index : { lifecycle : { name : 'some_index' , rollover_alias : 'some_index' } } } , } ) ; } ) ; } ) ;