コード例 #1
0
        public void TestUnitFromType_should_not_find_filter_types()
        {
            var asm  = TestAssembly.Create(GetType().Assembly);
            var test = asm.TestUnitFromType(typeof(Carbonfrost.Commons.Spec.ExecutionModel.TestFilters.UsingCultureFilter));

            Assert.Null(test);
        }
コード例 #2
0
        public void TestUnitFromType_should_find_private_methods(Type type)
        {
            var asm         = TestAssembly.Create(GetType().Assembly);
            var test        = asm.TestUnitFromType(type);
            var testContext = SelfTestUtility.NewTestContext(null, new FakeRunner());

            test.InitializeSafe(testContext);
            Assert.HasCount(
                1,
                test.Children
                );
            Assert.EndsWith(
                "PFact",
                test.Children[0].DisplayName
                );
        }
コード例 #3
0
        public void IsTestClassByAccess_should_find_private_classes(Type type)
        {
            var asm = TestAssembly.Create(GetType().Assembly);

            Assert.True(asm.IsTestClassByAccess(type));
        }
コード例 #4
0
        public void Description_comes_from_assembly_attribute()
        {
            var asm = TestAssembly.Create(GetType().Assembly);

            Assert.Equal("A unit testing framework", asm.Description);
        }