I determine the value of a variable in my Scenario file and want to store it in the Global hashtable for use within my strategy project.
In the Scenario file I use:
Code:
bool isContractRolled = false;
if (some tests) isContractRolled = true;
Strategy.Global.Add("didContractRoll", isContractRolled);
Console.WriteLine("Cnt of Globals: " + Strategy.Global.Count);
When I write to the console, I correctly get a value of 1.
In the Strategy code file:
Code:
Console.WriteLine("Count of Globals in strategy: " + Strategy.Global.Count);
returns 0.
Can someone please explain why the count is 0 in the strategy despite being 1 in the scenario? Am I missing some kind of declaration that allows the files to communicate?
Thank you.