File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
src/ServiceControl.Audit.Persistence.Tests.RavenDB Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,21 @@ public async Task Free_text_search_index_should_be_used_by_default()
3535 Assert . That ( freeTextIndex , Is . Not . Null ) ;
3636 }
3737
38+ [ Test ]
39+ public async Task Free_text_search_index_can_be_opted_out_from ( )
40+ {
41+ await DatabaseSetup . CreateIndexes ( configuration . DocumentStore , false , CancellationToken . None ) ;
42+
43+ //TODO: find a better way
44+ await Task . Delay ( 1000 ) ;
45+
46+ var freeTextIndex = await configuration . DocumentStore . Maintenance . SendAsync ( new GetIndexOperation ( DatabaseSetup . MessagesViewIndexWithFulltextSearchName ) ) ;
47+ var nonFreeTextIndex = await configuration . DocumentStore . Maintenance . SendAsync ( new GetIndexOperation ( DatabaseSetup . MessagesViewIndexName ) ) ;
48+
49+ Assert . That ( freeTextIndex , Is . Null ) ;
50+ Assert . That ( nonFreeTextIndex , Is . Not . Null ) ;
51+ }
52+
3853 [ Test ]
3954 public async Task Indexes_should_be_reset_on_setup ( )
4055 {
You can’t perform that action at this time.
0 commit comments