Ejemplo n.º 1
0
        private static void DoPolicySummary()
        {
            BasicTextSummaryWriter btss = new BasicTextSummaryWriter(PolicySetLoader.LoadPolicySet(m_args.InputFile));

            string output = btss.GetText();

            Console.Out.Write(output);
        }
		public void Test_p5default()
		{
			IPolicySet set = PolicySetLoader.LoadPolicySet(Path.Combine(TESTFILES, "p5default.policy"));

			BasicTextSummaryWriter writer = new BasicTextSummaryWriter(set);
			string actual = writer.GetText();

			string expected = File.ReadAllText(Path.Combine(TESTFILES, "p5default_expected.txt"));
            if (0 != string.Compare(expected, actual))
            {
                File.WriteAllText(Path.Combine(TESTFILES, "p5default_actual.txt"), actual);
            }

			Assert.AreEqual(expected, actual, "The actual BasicTextSummaryWriter output did not match with expected results>");
		}