public void GetObjectInfoTest1() { string strFilePath = Environment.CurrentDirectory + "\\VideoTypeInfoSource.xml"; string strParertName = "VideoTypeInfoSource"; string strNodeName = "VideoTypeInfo"; XmlNodeList x = XmlUse.GetNodeListInfo(strFilePath, strParertName, strNodeName); XmlNode node = x[0]; VideoTypeInfo result = XmlUse.GetObjectInfo <VideoTypeInfo>(node); Assert.AreEqual(result.VideoTypeName, "1"); }
public void GetObjectInfoTest() { string strFilePath = Environment.CurrentDirectory + "\\EntranceTypeInfo.xml"; string strParertName = "EntranceTypeInfo"; string strNodeName = "EntranceType"; XmlNodeList x = XmlUse.GetNodeListInfo(strFilePath, strParertName, strNodeName); XmlNode node = x[0]; EntranceType result = XmlUse.GetObjectInfo <EntranceType>(node); Assert.AreEqual(result.Key1, "1"); }