Exemplo n.º 1
0
        private static void Execute(ITestContext parentContext, ITestDescriptor testDescriptor)
        {
            if (testDescriptor.Identity == null)
            throw new TestCompositionException(string.Format("Test {0} should have identity", testDescriptor.GetType()));

              var context = testDescriptor.Execute(parentContext);
              foreach (var childDescriptor in testDescriptor.Children)
            Execute(context, childDescriptor);
              var disposable = context as IDisposable;
              if (disposable != null)
            disposable.Dispose();
        }