// BEFORE.Then<TransferInstructionCreatedChapter>();// NEW.ProceedToChapter<TransferInstructionCreatedChapter>();
// BEFOREScenario.Given.That.An_investor_has_been_created();// AFTERScenario.Given.An_investor_has_been_created();
Replace all references of IScenarioContext with ScenarioContext
Example this code:
public static readonly Func<ScenarioContext, StoryInput, StoryParameters, StoryOuput> AccountTransactionCreated =(context, input, parameters) =>{StoryOutput output = // Do Some work herereturn ouput;};
Should change to:
public static readonly Func<ScenarioContext<StoryInput>, StoryParameters, StoryOuput> AccountTransactionCreated =(context, parameters) =>{// Story Input is now accessed through the Scenario Contextvar storyInput = context.StoryInput;// Do work hereStoryOutput output = // Do Some work herereturn ouput;};
.UseResult(clientRegistered => newClient = clientRegistered );
refactored to:
.GetResult(out NewClientRegistered? newClient);