예제 #1
0
        protected override Pot CreateValueFromReader(IDatabaseReader reader)
        {
            var pot = new  Pot
                      (
                reader.GetInt("IDT"),
                reader.GetInt("TRPIDT"),
                reader.GetString("ORG"),
                ModelEnumConverter.PotModeFromString(reader.GetString("POTMOD")),
                reader.GetDouble("CURMNT"),
                reader.GetDouble("TGTMNT"),
                reader.GetString("NAM"),
                reader.GetDate("STRDAT"),
                reader.GetDate("ENDDAT"),
                reader.GetDate("VALDAT"),
                reader.GetString("DSC"),
                ConverterHelper.YesNoStringToBool(reader.GetString("INDCANCEL")),
                reader.GetString("CANCELRSN"),
                reader.GetNullableDate("CANCELDAT")
                      );

            pot.ModificationDate = reader.GetDate("DATEFT");
            return(pot);
        }
 public void PotModeFromString_ShouldReturnCorrectEnumValue(string mode, PotMode expected)
 {
     Assert.AreEqual(expected, ModelEnumConverter.PotModeFromString(mode));
 }