I have a dictionary that contains a class File in the value:
public Dictionary<string, File> mydict = new Dictionary<string, File>();
The class object File folder = new File() contains different variables such as First and Last (which are parsed from an xml) :
folder.First = Root.Attribute("First").Value;
folder.Last = Root.Attribute("Last").Value;
I want to know how I can grab variables inside the folder object inside the File class in my unit tests.
How can I use this data in my unit tests to work with
Assert.IsNotNull, Assert.AreEqual
mydict.Values.First().First, for example? - StriplingWarriorfolderto work with the Assert tests? If these were just regular variables, I could easily call them in myAsserttests using e.g.Assert.IsNotNull(<object>.First);but since they are inside themydictdictionary, I have trouble doing the unit testing - Sean Davis