public static bool UpdateStepValues(string TestStep, string Key, string Value) { bool success = true; if (!StepValues.ContainsKey(TestRun.TestStep)) { StepValues[TestRun.TestStep] = new Dictionary <string, string>(); } else { success = false; } if (!StepValues[TestRun.TestStep].ContainsKey(Key)) { StepValues[TestRun.TestStep][Key] = Value; } else { success = false; } if (success) { log.Info("Text value '" + StepValues[TestRun.TestStep][Key] + "' for test step '" + TestRun.TestStep + "', HTML Text Value stored in dictionary"); } else { log.Warn("Text value '" + StepValues[TestRun.TestStep][Key] + "' for test step '" + TestRun.TestStep + "', HTML Text already in dictionary"); } return(success); }