Пример #1
0
 public virtual void SetUp()
 {
     sysOutStream = new ByteArrayOutputStream();
     sysOut       = new TextWriter(sysOutStream);
     sysErrStream = new ByteArrayOutputStream();
     sysErr       = new TextWriter(sysErrStream);
     Runtime.SetOut(sysOut);
     cli = new RegistryCli(operations, CreateRegistryConfiguration(), sysOut, sysErr);
 }
Пример #2
0
        /// <exception cref="System.Exception"/>
        private void AssertResult(RegistryCli cli, int code, params string[] args)
        {
            int result = cli.Run(args);

            NUnit.Framework.Assert.AreEqual(code, result);
        }