public void RunTest() { Assert.AreEqual(Search.Searches.Length, expectedResults.Count, "Wrong number of searches in results file " + resultsFileName); foreach (Search search in Search.Searches) { string uuid = search.UUID; Assert.IsTrue(expectedResults.ContainsKey(uuid), "Couldn't find search with uuid " + uuid + " in results file " + resultsFileName); Search searcher = search; MW(() => ComparerAdapter.CompareResults(searcher, expectedResults[uuid])); } }
public static void CompareResults(Search search, XmlNode xmlNode) { ComparerAdapter adapter = new ComparerAdapter(search, xmlNode); search.PopulateAdapters(adapter); }