Наследование: ISolution
Пример #1
0
		public void TestEquals()
		{
			TestInstanceNamed("TestMatchName",
				(Solution sln, string solutionName, string tempPath, string filename) =>
				{
					ISolution otherSln = new Solution(filename);
					Assert.That(sln.Equals(otherSln), Is.True);
				});
		}
Пример #2
0
		private static void TestInstanceNamed(string solutionName, Action<Solution, string, string, string> asserts, string solutionText = null)
		{
			string tempPath = Path.GetTempPath();
			var filename = Path.Combine(tempPath, solutionName + ".sln");
			File.WriteAllText(filename, solutionText ?? partialSolutionTextWithTwoCSharpProjectsAndManySolutionFolders);
			try {
				var sln = new Solution(filename);
				Assert.That(sln, Is.Not.Null);
				asserts(sln, solutionName, tempPath, filename);
			} finally {
				File.Delete(filename);
			}
		}