コード例 #1
0
        public override void SetUp()
        {
            base.SetUp();

                Context = IntializeSpec(new RuleResult()
                                         {
                                             Description = "blah",
                                             RuleMessage = "this is our error message",
                                             Status = RuleStatus.Failed
                                         });
                consolewrapper = new Mock<IConsoleWrapper>();
                consolewrapper.SetupGet(x => x.ForegroundColor).Returns(ConsoleColor.DarkMagenta);

                ConsoleReportFactory reportfactory = new ConsoleReportFactory(consolewrapper.Object);
                reportfactory.FromSpecContainers(new[]{Context});
        }
コード例 #2
0
 public override void SetUp()
 {
     base.SetUp();
     Context = IntializeSpec(RuleStatus.Passed);
     var consolewrapper = new StringConsoleWrapper();
     ConsoleReportFactory reportfactory = new ConsoleReportFactory(consolewrapper);
     reportfactory.FromSpecContainers(new[]{Context});
     results = consolewrapper.Written;
 }