public void If_requested_it_should_return_the_correct_param_values_as_the_requested_type() { var args = new CmdArgumentsService(); args.Set("Argument1", "1"); args.Set("Argument2", 2.2.ToString(CultureInfo.CurrentCulture)); Assert.AreEqual(1, args.Get<int>("Argument1")); Assert.AreEqual(2.2, args.Get<double>("Argument2")); Assert.AreEqual(0, args.Get<int>("Argument3")); }
public void If_requested_it_should_return_the_correct_param_values_as_strings() { var args = new CmdArgumentsService(); args.Set("Argument1", "Value1"); args.Set("Argument2", "Value2"); Assert.AreEqual("Value1", args.Get("Argument1")); Assert.AreEqual("Value2", args.Get("Argument2")); Assert.IsNull(args.Get("Param3")); }