UnixOnlyTheoryAttribute.cs 518 B

1234567891011121314151617
  1. // Copyright (c) .NET Foundation and contributors. All rights reserved.
  2. // Licensed under the MIT license. See LICENSE file in the project root for full license information.
  3. namespace Microsoft.DotNet.Tools.Test.Utilities
  4. {
  5. public class UnixOnlyTheoryAttribute : TheoryAttribute
  6. {
  7. public UnixOnlyTheoryAttribute()
  8. {
  9. if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
  10. {
  11. this.Skip = "This test requires Unix to run";
  12. }
  13. }
  14. }
  15. }