mirror of
https://github.com/rosenbjerg/FFMpegCore.git
synced 2024-11-14 02:04:14 +01:00
79b0718d95
Former-commit-id: f33c060ff5
23 lines
No EOL
730 B
C#
23 lines
No EOL
730 B
C#
using System.Runtime.InteropServices;
|
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
|
|
|
namespace FFMpegCore.Test.Utilities;
|
|
|
|
public class WindowsOnlyDataTestMethod : DataTestMethodAttribute
|
|
{
|
|
public override TestResult[] Execute(ITestMethod testMethod)
|
|
{
|
|
if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
|
|
{
|
|
var message = $"Test not executed on other platforms than Windows";
|
|
{
|
|
return new[]
|
|
{
|
|
new TestResult { Outcome = UnitTestOutcome.Inconclusive, TestFailureException = new AssertInconclusiveException(message) }
|
|
};
|
|
}
|
|
}
|
|
|
|
return base.Execute(testMethod);
|
|
}
|
|
} |