C# Class NUnit.Framework.Internal.PlatformHelper

PlatformHelper class is used by the PlatformAttribute class to determine whether a platform is supported.
Mostra file Open project: nunit/nunit Class Usage Examples

Public Properties

Property Type Description
RuntimePlatforms string

Public Methods

Method Description
IsPlatformSupported ( PlatformAttribute platformAttribute ) : bool

Tests to determine if the current platform is supported based on a platform attribute.

IsPlatformSupported ( TestCaseAttribute testCaseAttribute ) : bool

Tests to determine if the current platform is supported based on a platform attribute.

IsPlatformSupported ( string platforms ) : bool

Test to determine if one of a collection of platforms is being used currently.

PlatformHelper ( ) : System

Default constructor uses the operating system and common language runtime of the system.

PlatformHelper ( OSPlatform os, RuntimeFramework rt ) : System

Construct a PlatformHelper for a particular operating system and common language runtime. Used in testing.

Private Methods

Method Description
IsPlatformSupported ( string include, string exclude ) : bool
IsRuntimeSupported ( RuntimeType runtime, string versionSpecification ) : bool
IsRuntimeSupported ( string platformName ) : bool

Method Details

IsPlatformSupported() public method

Tests to determine if the current platform is supported based on a platform attribute.
public IsPlatformSupported ( PlatformAttribute platformAttribute ) : bool
platformAttribute PlatformAttribute The attribute to examine
return bool

IsPlatformSupported() public method

Tests to determine if the current platform is supported based on a platform attribute.
public IsPlatformSupported ( TestCaseAttribute testCaseAttribute ) : bool
testCaseAttribute TestCaseAttribute The attribute to examine
return bool

IsPlatformSupported() public method

Test to determine if one of a collection of platforms is being used currently.
public IsPlatformSupported ( string platforms ) : bool
platforms string
return bool

PlatformHelper() public method

Default constructor uses the operating system and common language runtime of the system.
public PlatformHelper ( ) : System
return System

PlatformHelper() public method

Construct a PlatformHelper for a particular operating system and common language runtime. Used in testing.
public PlatformHelper ( OSPlatform os, RuntimeFramework rt ) : System
os OSPlatform OperatingSystem to be used
rt RuntimeFramework RuntimeFramework to be used
return System

Property Details

RuntimePlatforms public_oe static_oe property

Comma-delimited list of all supported Runtime platform constants
public static string RuntimePlatforms
return string