Pepino.ScenarioRunner.Application.ScenarioContext.GetPayloads C# (CSharp) Method

GetPayloads() public method

public GetPayloads ( ) : string>.IReadOnlyDictionary
return string>.IReadOnlyDictionary
        public IReadOnlyDictionary<string, string> GetPayloads()
        {
            return new ReadOnlyDictionary<string, string>(_responsePayloads);
        }

Usage Example

 string GetDependencies(ScenarioContext scenarioContext)
 {
     IEnumerable<string> dependencies = scenarioContext.GetPayloads()
         .Select(x => string.Format("var {0} = {1}", x.Key, x.Value));
     string dependenciesString = string.Join(";", dependencies);
     return dependenciesString;
 }