PageRenderTime 37ms CodeModel.GetById 12ms RepoModel.GetById 1ms app.codeStats 0ms

/src/NUnit/core/LegacySuite.cs

#
C# | 26 lines | 16 code | 2 blank | 8 comment | 0 complexity | 219f167b202bbe405d8a7b489cd5f287 MD5 | raw file
Possible License(s): GPL-2.0
  1. // ****************************************************************
  2. // This is free software licensed under the NUnit license. You
  3. // may obtain a copy of the license as well as information regarding
  4. // copyright ownership at http://nunit.org.
  5. // ****************************************************************
  6. using System;
  7. using System.Collections;
  8. using System.Reflection;
  9. namespace NUnit.Core
  10. {
  11. /// <summary>
  12. /// Represents a test suite constructed from a type that has a static Suite property
  13. /// </summary>
  14. public class LegacySuite : TestSuite
  15. {
  16. public LegacySuite( Type fixtureType ) : base( fixtureType )
  17. {
  18. this.fixtureSetUpMethods =
  19. Reflect.GetMethodsWithAttribute(fixtureType, NUnitFramework.FixtureSetUpAttribute, true);
  20. this.fixtureTearDownMethods =
  21. Reflect.GetMethodsWithAttribute(fixtureType, NUnitFramework.FixtureTearDownAttribute, true);
  22. }
  23. }
  24. }