Always create searchchain registry
@@ -153,7 +153,7 @@ public class Execution extends com.yahoo.processing.execution.Execution {
/** Create a Context instance where everything except the given arguments is empty. This is for unit testing.*/
public static Context createContextStub(SearchChainRegistry searchChainRegistry, IndexFacts indexFacts, Linguistics linguistics) {
- return new Context(searchChainRegistry,
+ return new Context(searchChainRegistry != null ? searchChainRegistry : new SearchChainRegistry(),
indexFacts,
null,
new RendererRegistry(Runnable::run),
