Beispiel #1
0
        private static void IncludeTestClasses([NotNull] IReportBuilder reportBuilder,
                                               [NotNull] IEnumerable <Assembly> assemblies)
        {
            const bool includeObsolete       = true;
            const bool includeInternallyUsed = true;

            foreach (Assembly assembly in assemblies)
            {
                foreach (Type testType in TestDescriptorUtils.GetTestClasses(
                             assembly, includeObsolete, includeInternallyUsed))
                {
                    foreach (int ctorIndex in TestDescriptorUtils.GetTestConstructorIndexes(
                                 testType,
                                 includeObsolete,
                                 includeInternallyUsed))
                    {
                        reportBuilder.IncludeTest(testType, ctorIndex);
                    }
                }
            }
        }