示例#1
0
 public void ClassFor()
 {
     Assert.AreEqual(ApplicationClass.WinForm, TestMode.Create("nunitconsole etc etc /exclude:FOOOOOOOO,Faaaa,WPF").ClassFor(new SampleTest()));
     Assert.AreEqual(ApplicationClass.WPF, TestMode.Create("nunitconsole etc etc /exclude:FOOOOOOOO,Faaaa,WinForm").ClassFor(new SampleTest()));
     Assert.AreEqual(ApplicationClass.WinForm,
                     TestMode.Create("nunitconsole etc etc /exclude:FOOOOOOOO,Faaaa,WinForm").ClassFor(new SampleWinFormsTest()));
     Assert.AreEqual(ApplicationClass.WinForm,
                     TestMode.Create("nunitconsole etc etc /exclude:\"FOOOOOOOO,Faaaa,WinForm\"").ClassFor(new SampleWinFormsTest()));
     Assert.AreEqual(ApplicationClass.WPF, TestMode.Create("nunitconsole etc etc /exclude:FOOOOOOOO,Faaaa,WinForm").ClassFor(new SampleWPFTest()));
     Assert.AreEqual(ApplicationClass.WinForm, TestMode.Create("nunitconsole etc etc /exclude:FOOOOOOOO,Faaaa,WPF").ClassFor(new SampleWinFormsTest()));
     Assert.AreEqual(ApplicationClass.WPF, TestMode.Create("nunitconsole etc etc /exclude:FOOOOOOOO,Faaaa,WPF").ClassFor(new SampleWPFTest()));
     Assert.AreEqual(ApplicationClass.WPF, TestMode.Create("nunitconsole etc etc /exclude:\"FOOOOOOOO,Faaaa,WPF\"").ClassFor(new SampleWPFTest()));
 }
示例#2
0
        public void CreatedWithoutCommandline()
        {
            Assert.AreEqual(ApplicationClass.WinForm, TestMode.Create(string.Empty).ClassFor(new SampleWinFormsTest()));
            Assert.AreEqual(ApplicationClass.WPF, TestMode.Create(string.Empty).ClassFor(new SampleWPFTest()));
            Assert.AreEqual(TestMode.DefaultAppClass, TestMode.Create(string.Empty).ClassFor(new SampleTest()));

            TestMode.DefaultAppClass = ApplicationClass.WinForm;
            Assert.AreEqual(TestMode.DefaultAppClass, TestMode.Create(string.Empty).ClassFor(new SampleMultiCategoryTest()));
            TestMode.DefaultAppClass = ApplicationClass.WPF;
            Assert.AreEqual(TestMode.DefaultAppClass, TestMode.Create(string.Empty).ClassFor(new SampleMultiCategoryTest()));
            TestMode.DefaultAppClass = ApplicationClass.SWT;
            Assert.AreNotEqual(TestMode.DefaultAppClass, TestMode.Create(string.Empty).ClassFor(new SampleMultiCategoryTest()));
        }
示例#3
0
 public void Create()
 {
     Assert.AreEqual(new TestMode(ApplicationClass.SWT), TestMode.Create("nunitconsole etc etc /exclude:WPF,Normal,WinForm"));
     Assert.AreEqual(new TestMode(ApplicationClass.SWT), TestMode.Create("nunitconsole etc etc /exclude:\"WPF,Normal,WinForm\""));
     Assert.AreEqual(new TestMode(ApplicationClass.SWT), TestMode.Create("nunitconsole etc etc /exclude:\"WPF, Normal, WinForm\""));
 }