public void DirectMappingWorksCorrectly() { DirectMapping direct = new DirectMapping("X"); Dictionary <string, object> inputRow = new Dictionary <string, object>(); inputRow.Add("X", "a"); inputRow.Add("Y", "b"); object expected = "a"; object actual = direct.GetValue(inputRow); Assert.AreEqual(expected, actual, "Direct mapping didn't extract correct value"); }
public void DirectMappingWorksCorrectlyWhenBlank() { DirectMapping direct = new DirectMapping("Z"); Dictionary <string, object> inputRow = new Dictionary <string, object>(); inputRow.Add("X", "a"); inputRow.Add("Y", "b"); object expected = ""; object actual = direct.GetValue(inputRow); Assert.AreEqual(expected, actual, "Direct mapping didn't extract null when couldn't find value"); }