PageRenderTime 53ms CodeModel.GetById 25ms RepoModel.GetById 0ms app.codeStats 0ms

/src/NUnit/framework/Attributes/DescriptionAttribute.cs

#
C# | 37 lines | 17 code | 4 blank | 16 comment | 0 complexity | 86e19c0868a016281596af3cbf98773c MD5 | raw file
Possible License(s): GPL-2.0
  1. // ****************************************************************
  2. // Copyright 2007, Charlie Poole
  3. // This is free software licensed under the NUnit license. You may
  4. // obtain a copy of the license at http://nunit.org
  5. // ****************************************************************
  6. using System;
  7. namespace NUnit.Framework
  8. {
  9. /// <summary>
  10. /// Attribute used to provide descriptive text about a
  11. /// test case or fixture.
  12. /// </summary>
  13. [AttributeUsage(AttributeTargets.Class|AttributeTargets.Method|AttributeTargets.Assembly, AllowMultiple=false, Inherited=false)]
  14. public class DescriptionAttribute : Attribute
  15. {
  16. string description;
  17. /// <summary>
  18. /// Construct the attribute
  19. /// </summary>
  20. /// <param name="description">Text describing the test</param>
  21. public DescriptionAttribute(string description)
  22. {
  23. this.description=description;
  24. }
  25. /// <summary>
  26. /// Gets the test description
  27. /// </summary>
  28. public string Description
  29. {
  30. get { return description; }
  31. }
  32. }
  33. }