### APIDOC: Xunit.v3.ExtensibilityPointFactory.Get Method Details Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.ExtensibilityPointFactory.Get Detailed API documentation for the Get method, including its namespace, assembly, parameters, return type, and type parameters. It explains how the method instantiates types, handles constructor arguments, and manages optional diagnostic message sinks. ```APIDOC Namespace: Xunit.v3 Assembly: xunit.v3.core.dll Method: Get(Type?, object?[]?) Description: Gets an instance of the given type, casting it to TInterface, using the provided constructor arguments. Parameters: type: Type The implementation type. ctorArgs: object[] The constructor arguments. Since diagnostic message sinks are optional, the code first looks for a type that takes the given arguments plus the message sink, and only falls back to the message sink-less constructor if none was found. Returns: TInterface The instance of the type. Type Parameters: TInterface The interface type. ``` -------------------------------- ### API Documentation for Launch Method Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.ITestProcessLauncher.Launch Provides a detailed API reference for the `Launch` method, including its namespace, assembly, signature, parameter descriptions, and return type. This method is used to start a test process, returning an `ITestProcess` instance or `null` if the launch fails. ```APIDOC Method: Launch Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Description: Launches the test process. Returns null if the process could not be launched. Signature: ITestProcess? Launch(XunitProjectAssembly projectAssembly, IReadOnlyList arguments) Parameters: projectAssembly: The test project assembly arguments: IReadOnlyList - The list of arguments to be passed to the in-process runner Returns: ITestProcess? ``` ```C# ITestProcess? Launch(XunitProjectAssembly projectAssembly, IReadOnlyList arguments) ``` -------------------------------- ### HandleTestStarting method for VstsReporterMessageHandler Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Handles the start of a test case. This method is part of the IRunnerReporterMessageHandler interface, processing messages related to individual test execution. ```C# void HandleTestStarting(TestStarting testStarting); ``` -------------------------------- ### TestAssemblyStarting Properties Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Represents the event data for when a test assembly starts execution. It includes properties like assembly name, path, configuration file path, target framework, and start time. ```C# public string AssemblyName { get; } ``` ```C# public string AssemblyPath { get; } ``` ```C# public string ConfigFilePath { get; } ``` ```C# public int Seed { get; } ``` ```C# public DateTimeOffset StartTime { get; } ``` ```C# public string TargetFramework { get; } ``` ```C# public TestEnvironment TestEnvironment { get; } ``` ```C# public string TestFrameworkDisplayName { get; } ``` ```C# public IReadOnlyList Traits { get; } ``` -------------------------------- ### Xunit.Convert Method API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.TheoryData-3.Convert Detailed API documentation for the `Convert` method, including its signature, parameters, and a C# code example of its protected override implementation. ```C# protected override TheoryDataRow Convert((T1, T2, T3) row) ``` ```APIDOC Method: Convert Namespace: Xunit Assembly: xunit.v3.core.dll Signature: Convert((T1, T2, T3)) Description: Convert untyped values into the appropriate theory data row. Parameters: row: Type: (T1, T2, T3) Description: The raw data row Returns: TheoryDataRow (Implied from signature) ``` -------------------------------- ### Find Method API Documentation (Xunit.v3) Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.TestProcessLauncherAdapter.Find Detailed API documentation for the `Find` method, which starts the process of finding tests in an assembly. It requires assembly information, message sinks for results and diagnostics, and an optional source information provider. ```APIDOC Method: Find Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Signature: public ITestProcessBase Find(XunitProjectAssembly projectAssembly, TestAssemblyInfo assemblyInfo, IMessageSink messageSink, IMessageSink? diagnosticMessageSink, ISourceInformationProvider? sourceInformationProvider) Parameters: projectAssembly: The test assembly assemblyInfo: The test assembly information (from GetAssemblyInfo(XunitProjectAssembly)) messageSink: The message sink to report results back to. diagnosticMessageSink: The message to report diagnostic messages to. sourceInformationProvider: The source information provider used to add file and line information to discovered tests Returns: ITestProcessBase ``` -------------------------------- ### Xunit2Options Constructor and Methods Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Constructor and methods for Xunit2Options, used for configuring Xunit2 execution options, including getting and setting values. ```C# public Xunit2Options(); ``` ```C# public T GetValue(); ``` ```C# public void SetValue(T value); ``` -------------------------------- ### HandleTestAssemblyStarting method for VstsReporterMessageHandler Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Handles the start of a test assembly. This method is part of the IRunnerReporterMessageHandler interface, processing messages related to test execution phases. ```C# void HandleTestAssemblyStarting(TestAssemblyStarting testAssemblyStarting); ``` -------------------------------- ### C# Method Signature for Get Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.ExtensibilityPointFactory.Get The public static method signature for Get, which retrieves an instance of a given type and casts it to the specified interface, optionally using constructor arguments. ```C# public static TInterface? Get(Type? type, object?[]? ctorArgs = null) where TInterface : class ``` -------------------------------- ### Xunit.v3.Run Method API Reference Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.TestProcessLauncherAdapter.Run Detailed API reference for the `Run` method, including its namespace, assembly, parameters with types and descriptions, and return type, for initiating test execution. ```APIDOC Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Method: Run Description: Starts the process of running tests in the assembly. Signature: public ITestProcessBase Run(XunitProjectAssembly projectAssembly, TestAssemblyInfo assemblyInfo, IMessageSink messageSink, IMessageSink? diagnosticMessageSink, ISourceInformationProvider? sourceInformationProvider) Parameters: projectAssembly: Type: XunitProjectAssembly Description: The test assembly assemblyInfo: Type: TestAssemblyInfo Description: The test assembly information (from GetAssemblyInfo(XunitProjectAssembly)) messageSink: Type: IMessageSink Description: The message sink to report results back to. diagnosticMessageSink: Type: IMessageSink? Description: The message to report diagnostic messages to. sourceInformationProvider: Type: ISourceInformationProvider? Description: The source information provider used to add file and line information to discovered tests Returns: ITestProcessBase ``` -------------------------------- ### Get(Type?, object?[]) API Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.ExtensibilityPointFactory Gets an instance of the given type, casting it to the specified TInterface, using the provided constructor arguments. ```APIDOC Get(type: System.Type?, constructorArguments: System.Object[]?) Description: Gets an instance of the given type, casting it to TInterface, using the provided constructor arguments. ``` -------------------------------- ### APIDOC: Xunit.v3.StartTestProcess Method Details Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.LocalOutOfProcessTestProcessLauncher.StartTestProcess Comprehensive API documentation for the `StartTestProcess` method, covering its namespace, assembly, parameters with types and descriptions, implied return type, and important remarks regarding its usage and responsibilities. ```APIDOC Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Method: StartTestProcess(string executable, string executableArguments, string? responseFile) Description: Starts the test process. Parameters: executable (string): The executable to be launched (note that this may not be a fully qualified path name, as it may be depending on the system path to locate the executable) executableArguments (string): The arguments to pass to the executable responseFile (string): The response file that's being used, if present Returns: ITestProcess? (from signature) Remarks: The response file will be part of the `executableArguments`, but the actual path to the response file is provided here in the even that it needs to be modified or copied elsewhere (at which point the developer is responsible for updating `executableArguments` to point to the new response file location). Additionally, the developer is responsible for deleting the response file from the disk when the execution is complete. ``` -------------------------------- ### Test Starting Message Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Indicates the start of a test execution. Contains properties like display name, timeout, and traits. ```C# public class TestStarting { public bool Explicit { get; } public DateTime StartTime { get; } public string TestDisplayName { get; } public TimeSpan Timeout { get; } public ITrait[] Traits { get; } public static TestStarting Deserialize(IXunitSerializationInfo info); public void Serialize(IXunitSerializationInfo info); public override string ToString(); } ``` -------------------------------- ### Xunit1TestCase Methods Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Details methods for converting Xunit1TestCase to different test case states, such as discovered, starting, finished, passed, failed, and skipped. ```C# public static TestCaseDiscovered ToTestCaseDiscovered(ITestCase testCase); ``` ```C# public static TestCaseFinished ToTestCaseFinished(ITestCase testCase); ``` ```C# public static TestCaseFinishedNotRun ToTestCaseFinishedNotRun(ITestCase testCase); ``` ```C# public static TestCaseStarting ToTestCaseStarting(ITestCase testCase); ``` ```C# public static TestFailed ToTestFailed(ITestCase testCase, string exceptionType, string message, string stackTrace); ``` ```C# public static TestFinished ToTestFinished(ITestCase testCase); ``` ```C# public static TestFinishedNotRun ToTestFinishedNotRun(ITestCase testCase); ``` ```C# public static TestMethodFinished ToTestMethodFinished(ITestCase testCase); ``` ```C# public static TestMethodFinishedNotRun ToTestMethodFinishedNotRun(ITestCase testCase); ``` ```C# public static TestMethodStarting ToTestMethodStarting(ITestCase testCase); ``` ```C# public static TestNotRun ToTestNotRun(ITestCase testCase, string skipReason); ``` ```C# public static TestOutput ToTestOutput(ITestCase testCase, string output); ``` ```C# public static TestPassed ToTestPassed(ITestCase testCase); ``` ```C# public static TestSkipped ToTestSkipped(ITestCase testCase, string skipReason); ``` ```C# public static TestStarting ToTestStarting(ITestCase testCase); ``` -------------------------------- ### Test Method Starting Message Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Indicates the start of a test method execution. Includes properties for the method name and associated traits. ```C# public class TestMethodStarting { public string MethodName { get; } public ITrait[] Traits { get; } public static TestMethodStarting Deserialize(IXunitSerializationInfo info); public void Serialize(IXunitSerializationInfo info); public override string ToString(); } ``` -------------------------------- ### APIDOC: FrontControllerLaunchOptions Class Details Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.FrontControllerLaunchOptions Comprehensive API documentation for the `FrontControllerLaunchOptions` class, including its namespace, assembly, inheritance hierarchy, and a list of inherited members from `System.Object`. ```APIDOC Class: FrontControllerLaunchOptions Namespace: Xunit Assembly: xunit.v3.runner.common.dll Description: Launch options when using IFrontController and/or IFrontControllerDiscoverer. Current only supported by v3 test projects (all options will be ignored for v1/v2 test projects). Inheritance: - System.Object - FrontControllerLaunchOptions Inherited Members (from System.Object): - Equals(object) - Equals(object, object) - GetHashCode() - GetType() - MemberwiseClone() - ReferenceEquals(object, object) - ToString() ``` -------------------------------- ### StartsWith Method (ReadOnlySpan, ReadOnlySpan) API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Documents the `StartsWith` method overload that verifies if a string starts with a given substring using the current culture, accepting `ReadOnlySpan` for both the expected start string and the actual string. It throws an exception if the string does not start with the expected substring. ```APIDOC Method: StartsWith Signature: public static void StartsWith(ReadOnlySpan expectedStartString, ReadOnlySpan actualString) Description: Verifies that a string starts with a given sub-string, using the current culture. Parameters: expectedStartString: ReadOnlySpan - The sub-string expected to be at the start of the string actualString: ReadOnlySpan - The string to be inspected Exceptions: Thrown when the string does not start with the expected sub-string ``` -------------------------------- ### APIDOC: FrontControllerFindAndRunSettings Constructor Details Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.FrontControllerFindAndRunSettings.-ctor Detailed API documentation for the FrontControllerFindAndRunSettings constructor, outlining its namespace, assembly, and a comprehensive breakdown of each parameter with its type and description. ```APIDOC Namespace: Xunit Assembly: xunit.v3.runner.common.dll Constructor: FrontControllerFindAndRunSettings(ITestFrameworkDiscoveryOptions discoveryOptions, ITestFrameworkExecutionOptions executionOptions, XunitFilters? filters = null) Description: Contains the information used by FindAndRun(IMessageSink, FrontControllerFindAndRunSettings). Parameters: discoveryOptions: ITestFrameworkDiscoveryOptions Description: The options used during discovery executionOptions: ITestFrameworkExecutionOptions Description: The options used during execution filters: XunitFilters? Description: The optional filters (when not provided, finds all tests) ``` -------------------------------- ### TestCaseStarting Properties Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Represents data for a test case starting execution, including its display name, source file path, line number, and any associated traits or skip reasons. ```C# public bool Explicit { get; } ``` ```C# public string SkipReason { get; } ``` ```C# public string SourceFilePath { get; } ``` ```C# public int SourceLineNumber { get; } ``` ```C# public string TestCaseDisplayName { get; } ``` ```C# public int TestClassMetadataToken { get; } ``` ```C# public string TestClassName { get; } ``` ```C# public string TestClassNamespace { get; } ``` ```C# public string TestClassSimpleName { get; } ``` ```C# public int TestMethodMetadataToken { get; } ``` ```C# public string TestMethodName { get; } ``` ```C# public string TestMethodParameterTypesVSTest { get; } ``` ```C# public string TestMethodReturnTypeVSTest { get; } ``` ```C# public IReadOnlyList Traits { get; } ``` -------------------------------- ### AssemblyRunnerStartOptions Properties Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Properties for AssemblyRunnerStartOptions, used to configure the start of an assembly run, including diagnostic messages, parallel execution, and method display options. ```C# public bool DiagnosticMessages { get; set; } ``` ```C# public static AssemblyRunnerStartOptions Empty { get; } ``` ```C# public bool InternalDiagnosticMessages { get; set; } ``` ```C# public int MaxParallelThreads { get; set; } ``` ```C# public MethodDisplay MethodDisplay { get; set; } ``` ```C# public MethodDisplayOptions MethodDisplayOptions { get; set; } ``` ```C# public ParallelOption Parallel { get; set; } ``` ```C# public ParallelAlgorithm ParallelAlgorithm { get; set; } ``` ```C# public bool PreEnumerateTheories { get; set; } ``` -------------------------------- ### API Documentation for Xunit.SetForInitialization Method Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.TestContext.SetForInitialization Comprehensive API documentation for the `SetForInitialization` method, including its namespace, assembly, full signature, purpose, and detailed parameter descriptions. ```APIDOC Method: SetForInitialization Namespace: Xunit Assembly: xunit.v3.core.dll Signature: public static void SetForInitialization(IMessageSink? diagnosticMessageSink, bool diagnosticMessages, bool internalDiagnosticMessages) Description: Sets the test context for test framework initialization. This is the moment before any specific assembly is being discovered or run. This is typically used by custom runners just before they create the test framework via a call to GetTestFramework(Assembly). Parameters: diagnosticMessageSink: Type: IMessageSink? Description: The optional message sink used to receive IDiagnosticMessage and IInternalDiagnosticMessage instances. diagnosticMessages: Type: bool Description: A flag to indicate whether the user wants to receive diagnostic messages internalDiagnosticMessages: Type: bool Description: A flag to indicate whether the user wants to receive internal diagnostic messages ``` -------------------------------- ### Get Attribute Type Identifier (System.Attribute) Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.MemberDataAttributeBase Gets a unique identifier for this attribute. When overridden in a derived class, this property can be used to distinguish between two attributes of the same type. ```APIDOC Attribute.TypeId ``` -------------------------------- ### AfterTestStarting Serialization and Methods Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Represents the message sent before a test starts. Includes properties for attribute names and methods for serialization and deserialization. ```C# public string AttributeName { get; } public static AfterTestStarting Deserialize(IXunitSerialization V1) public string Serialize() public override string ToString() ``` -------------------------------- ### StartsWith Method (ReadOnlySpan, Span) API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Documents the `StartsWith` method overload that verifies if a string starts with a given substring using the current culture, accepting `ReadOnlySpan` for the expected start string and `Span` for the actual string. It throws an exception if the string does not start with the expected substring. ```APIDOC Method: StartsWith Signature: public static void StartsWith(ReadOnlySpan expectedStartString, Span actualString) Description: Verifies that a string starts with a given sub-string, using the current culture. Parameters: expectedStartString: ReadOnlySpan - The sub-string expected to be at the start of the string actualString: Span - The string to be inspected Exceptions: Thrown when the string does not start with the expected sub-string ``` -------------------------------- ### APIDOC: ITestProcessDirectLauncher Interface and Methods Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.ITestProcessDirectLauncher Detailed API documentation for the `ITestProcessDirectLauncher` interface, including its namespace, assembly, overall purpose, remarks on its higher-level nature, and a list of its methods with their descriptions and parameters. ```APIDOC Interface ITestProcessDirectLauncher Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Description: Implement this to control the launch of an xUnit.net v3 test process. Remarks: This is a higher level API than ITestProcessLauncher which allows more optimized communication rather than mandating all message passing is done via text readers/writers that represent standard input and standard output. Launchers that do not implement this interface with be adapted by TestProcessLauncherAdapter. Methods: Find(XunitProjectAssembly, TestAssemblyInfo, IMessageSink, IMessageSink?, ISourceInformationProvider?) Description: Starts the process of finding tests in an assembly. Parameters: - XunitProjectAssembly - TestAssemblyInfo - IMessageSink - IMessageSink? - ISourceInformationProvider? GetAssemblyInfo(XunitProjectAssembly) Description: Gets the test assembly metadata. Parameters: - XunitProjectAssembly Run(XunitProjectAssembly, TestAssemblyInfo, IMessageSink, IMessageSink?, ISourceInformationProvider?) Description: Starts the process of running tests in the assembly. Parameters: - XunitProjectAssembly - TestAssemblyInfo - IMessageSink - IMessageSink? - ISourceInformationProvider? ``` -------------------------------- ### Get Object Type (System.Object) Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.MemberDataAttributeBase Gets the Type of the current instance. This method is inherited from System.Object and returns a Type object that represents the exact runtime type of the instance. ```APIDOC object.GetType() ``` -------------------------------- ### WithLaunchOptions method for XunitProject Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Configures launch options for the xUnit.net project. This method allows specifying how the test runner should be launched. ```C# XunitProject WithLaunchOptions(LaunchOptions options); ``` -------------------------------- ### StartsWith Method (ReadOnlySpan, ReadOnlySpan, StringComparison) API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Documents the `StartsWith` method overload that verifies if a string starts with a given substring using a specified comparison type. It accepts `ReadOnlySpan` for both the expected start string and the actual string, and a `StringComparison` enum for the comparison type. It throws an exception if the string does not start with the expected substring. ```APIDOC Method: StartsWith Signature: public static void StartsWith(ReadOnlySpan expectedStartString, ReadOnlySpan actualString, StringComparison comparisonType = StringComparison.CurrentCulture) Description: Verifies that a string starts with a given sub-string, using the given comparison type. Parameters: expectedStartString: ReadOnlySpan - The sub-string expected to be at the start of the string actualString: ReadOnlySpan - The string to be inspected comparisonType: StringComparison - The type of string comparison to perform Exceptions: Thrown when the string does not start with the expected sub-string ``` -------------------------------- ### APIDOC: FrontControllerLaunchOptions Properties Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.FrontControllerLaunchOptions Documents the properties available in the `FrontControllerLaunchOptions` class, detailing their purpose. ```APIDOC Properties: - Name: WaitForDebugger Description: Wait for a debugger to be attached before performing any operations. ``` -------------------------------- ### C# Signature for Xunit.v3.Run Method Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.TestProcessLauncherAdapter.Run The C# method signature for the `Run` method, showing its return type and all required parameters for initiating test execution. ```csharp public ITestProcessBase Run(XunitProjectAssembly projectAssembly, TestAssemblyInfo assemblyInfo, IMessageSink messageSink, IMessageSink? diagnosticMessageSink, ISourceInformationProvider? sourceInformationProvider) ``` -------------------------------- ### StartsWith Method (Span, Span, StringComparison) API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Documents the `StartsWith` method overload that verifies if a string starts with a given substring using a specified comparison type. It accepts `Span` for both the expected start string and the actual string, and a `StringComparison` enum for the comparison type. It throws an exception if the string does not start with the expected substring. ```APIDOC Method: StartsWith Signature: public static void StartsWith(Span expectedStartString, Span actualString, StringComparison comparisonType = StringComparison.CurrentCulture) Description: Verifies that a string starts with a given sub-string, using the given comparison type. Parameters: expectedStartString: Span - The sub-string expected to be at the start of the string actualString: Span - The string to be inspected comparisonType: StringComparison - The type of string comparison to perform Exceptions: Thrown when the string does not start with the expected sub-string ``` -------------------------------- ### TestProcessLauncherAdapter Constructor and Methods Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Details the TestProcessLauncherAdapter class, used for launching and managing test processes. Includes methods like Find, GetAssemblyInfo, and Run. ```C# public class TestProcessLauncherAdapter : ITestProcessLauncher { public TestProcessLauncherAdapter(ITestAssemblyConfiguration testAssemblyConfiguration); public ITestDiscoverer Find(ITestAssembly testAssembly, string assemblyPath); public TestAssemblyInfo GetAssemblyInfo(string assemblyPath); public void Run(ITestAssembly testAssembly, string assemblyPath, TestFrameworkDiscoveryOptions discoveryOptions, TestFrameworkExecutionOptions executionOptions); } ``` -------------------------------- ### Get Default Test Collection for Assembly Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index The CollectionPerAssemblyTestCollectionFactory is responsible for creating test collections based on the assembly. It provides a method to get the default test collection for a given assembly. ```C# public class CollectionPerAssemblyTestCollectionFactory : ITestCollectionFactory { public CollectionPerAssemblyTestCollectionFactory(); public string DisplayName { get; set; } public virtual TestCollection GetDefaultTestCollection(TestCollectionFactoryContext context); } ``` -------------------------------- ### StartsWith Method (ReadOnlySpan, Span, StringComparison) API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Documents the `StartsWith` method overload that verifies if a string starts with a given substring using a specified comparison type. It accepts `ReadOnlySpan` for the expected start string, `Span` for the actual string, and a `StringComparison` enum for the comparison type. It throws an exception if the string does not start with the expected substring. ```APIDOC Method: StartsWith Signature: public static void StartsWith(ReadOnlySpan expectedStartString, Span actualString, StringComparison comparisonType = StringComparison.CurrentCulture) Description: Verifies that a string starts with a given sub-string, using the given comparison type. Parameters: expectedStartString: ReadOnlySpan - The sub-string expected to be at the start of the string actualString: Span - The string to be inspected comparisonType: StringComparison - The type of string comparison to perform Exceptions: Thrown when the string does not start with the expected sub-string ``` -------------------------------- ### API Documentation for InitializeLifetimeService Method Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.AssemblyHelper.InitializeLifetimeService Detailed API documentation for the `InitializeLifetimeService` method, including its purpose, signature, return values, and potential exceptions within the Xunit framework. ```csharp [SecurityCritical] public override sealed object InitializeLifetimeService() ``` ```APIDOC Namespace: Xunit Assembly: xunit.v3.runner.utility.netfx.dll Method: InitializeLifetimeService() Description: Obtains a lifetime service object to control the lifetime policy for this instance. Returns: Type: object Description: An object of type ILease used to control the lifetime policy for this instance. This is the current lifetime service object for this instance if one exists; otherwise, a new lifetime service object initialized to the value of the LeaseManagerPollTime property. Exceptions: SecurityException: Description: The immediate caller does not have infrastructure permission. ``` -------------------------------- ### StartsWith Method (Span, ReadOnlySpan, StringComparison) API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Documents the `StartsWith` method overload that verifies if a string starts with a given substring using a specified comparison type. It accepts `Span` for the expected start string, `ReadOnlySpan` for the actual string, and a `StringComparison` enum for the comparison type. It throws an exception if the string does not start with the expected substring. ```APIDOC Method: StartsWith Signature: public static void StartsWith(Span expectedStartString, ReadOnlySpan actualString, StringComparison comparisonType = StringComparison.CurrentCulture) Description: Verifies that a string starts with a given sub-string, using the given comparison type. Parameters: expectedStartString: Span - The sub-string expected to be at the start of the string actualString: ReadOnlySpan - The string to be inspected comparisonType: StringComparison - The type of string comparison to perform Exceptions: Thrown when the string does not start with the expected sub-string ``` -------------------------------- ### Xunit.FrontControllerFindSettings Constructors Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.FrontControllerFindSettings Documents the constructor for the `FrontControllerFindSettings` class, detailing its parameters and their role in initializing the settings for test discovery. ```APIDOC Constructors: - FrontControllerFindSettings(ITestFrameworkDiscoveryOptions options, XunitFilters? filters) Description: Contains the information by Find(IMessageSink, FrontControllerFindSettings). Parameters: - options: ITestFrameworkDiscoveryOptions - The options used during discovery. - filters: XunitFilters? - The test case filters used during discovery. ``` -------------------------------- ### StartTestProcess Method API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.OutOfProcessTestProcessLauncherBase.StartTestProcess Documents the `StartTestProcess` method within the `Xunit.v3` namespace, detailing its purpose, parameters, and usage remarks for launching test processes. ```csharp protected abstract ITestProcess? StartTestProcess(string executable, string executableArguments, string? responseFile) ``` ```APIDOC Method: StartTestProcess Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Description: Starts the test process. Parameters: executable (string): The executable to be launched (note that this may not be a fully qualified path name, as it may be depending on the system path to locate the executable) executableArguments (string): The arguments to pass to the executable responseFile (string?): The response file that's being used, if present Returns: ITestProcess? Remarks: The response file will be part of the executableArguments, but the actual path to the response file is provided here in the even that it needs to be modified or copied elsewhere (at which point the developer is responsible for updating executableArguments to point to the new response file location). Additionally, the developer is responsible for deleting the response file from the disk when the execution is complete. ``` -------------------------------- ### Verify String Starts With Substring in xUnit.Assert Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.Assert These methods in xUnit.Assert verify if a given string starts with a specified substring. Overloads are available for `Span` and `string` types, and allow specifying a `StringComparison` type for culture-sensitive or invariant comparisons. ```APIDOC StartsWith(Span, Span) ``` ```APIDOC StartsWith(Span, Span, StringComparison) ``` ```APIDOC StartsWith(string?, string?) ``` ```APIDOC StartsWith(string?, string?, StringComparison) ``` -------------------------------- ### ITestPipelineStartup Methods Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Methods for the ITestPipelineStartup interface, defining actions for the test pipeline startup. ```C# public Task StartAsync(ITestFrameworkExecutionOptions executionOptions) public Task StopAsync(ITestFrameworkExecutionOptions executionOptions) ``` -------------------------------- ### Xunit.v3.Run Method API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.ITestProcessDirectLauncher.Run Provides the API specification for the Run method, used to initiate test execution within a specified assembly. It requires various sinks for reporting results and diagnostics, and a source information provider. ```APIDOC Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Method: Run Description: Starts the process of running tests in the assembly. Signature: ITestProcessBase Run(XunitProjectAssembly projectAssembly, TestAssemblyInfo assemblyInfo, IMessageSink messageSink, IMessageSink? diagnosticMessageSink, ISourceInformationProvider? sourceInformationProvider) Parameters: projectAssembly: The test assembly assemblyInfo: The test assembly information (from GetAssemblyInfo(XunitProjectAssembly)) messageSink: The message sink to report results back to. diagnosticMessageSink: The message to report diagnostic messages to. sourceInformationProvider: The source information provider used to add file and line information to discovered tests Returns: ITestProcessBase ``` -------------------------------- ### xUnit.net Assert: Verify String Starts With Methods Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.Assert A set of overloaded methods to verify if a string starts with a specified sub-string. These methods support various memory and span types for string representation and allow for custom string comparison rules. ```APIDOC StartsWith(Memory, Memory): Verifies that a string starts with a given sub-string, using the current culture. ``` ```APIDOC StartsWith(Memory, Memory, StringComparison): Verifies that a string starts with a given sub-string, using the given comparison type. ``` ```APIDOC StartsWith(Memory, ReadOnlyMemory): Verifies that a string starts with a given sub-string, using the current culture. ``` ```APIDOC StartsWith(Memory, ReadOnlyMemory, StringComparison): Verifies that a string starts with a given sub-string, using the given comparison type. ``` ```APIDOC StartsWith(ReadOnlyMemory, Memory): Verifies that a string starts with a given sub-string, using the current culture. ``` ```APIDOC StartsWith(ReadOnlyMemory, Memory, StringComparison): Verifies that a string starts with a given sub-string, using the given comparison type. ``` ```APIDOC StartsWith(ReadOnlyMemory, ReadOnlyMemory): Verifies that a string starts with a given sub-string, using the default StringComparison.CurrentCulture comparison type. ``` ```APIDOC StartsWith(ReadOnlyMemory, ReadOnlyMemory, StringComparison): Verifies that a string starts with a given sub-string, using the given comparison type. ``` ```APIDOC StartsWith(ReadOnlySpan, ReadOnlySpan): Verifies that a string starts with a given sub-string, using the current culture. ``` ```APIDOC StartsWith(ReadOnlySpan, ReadOnlySpan, StringComparison): Verifies that a string starts with a given sub-string, using the given comparison type. ``` ```APIDOC StartsWith(ReadOnlySpan, Span): Verifies that a string starts with a given sub-string, using the current culture. ``` ```APIDOC StartsWith(ReadOnlySpan, Span, StringComparison): Verifies that a string starts with a given sub-string, using the given comparison type. ``` ```APIDOC StartsWith(Span, ReadOnlySpan): Verifies that a string starts with a given sub-string, using the current culture. ``` ```APIDOC StartsWith(Span, ReadOnlySpan, StringComparison): Verifies that a string starts with a given sub-string, using the given comparison type. ``` -------------------------------- ### APIDOC: Xunit.v3.TestProcessLauncherAdapter Class Reference Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.TestProcessLauncherAdapter Comprehensive API documentation for the TestProcessLauncherAdapter class in xUnit.v3, detailing its structure, inheritance, implemented interfaces, constructors, and methods for managing test processes. ```APIDOC Class TestProcessLauncherAdapter Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Description: This class adapts ITestProcessLauncher into ITestProcessDirectLauncher, including static versions that can be used be an implementation of ITestProcessDirectLauncher that must fall back to using ITestProcessLauncher code due to version requirements. Inheritance: - object - TestProcessLauncherAdapter Implements: - ITestProcessDirectLauncher Inherited Members (from object): - ToString() - Equals(object) - Equals(object, object) - ReferenceEquals(object, object) - GetHashCode() - GetType() - MemberwiseClone() Constructors: - TestProcessLauncherAdapter(ITestProcessLauncher) Description: This class adapts ITestProcessLauncher into ITestProcessDirectLauncher, including static versions that can be used be an implementation of ITestProcessDirectLauncher that must fall back to using ITestProcessLauncher code due to version requirements. Methods: - Find(XunitProjectAssembly, TestAssemblyInfo, IMessageSink, IMessageSink?, ISourceInformationProvider?) Description: Starts the process of finding tests in an assembly. - GetAssemblyInfo(XunitProjectAssembly) Description: Gets the test assembly metadata. - Run(XunitProjectAssembly, TestAssemblyInfo, IMessageSink, IMessageSink?, ISourceInformationProvider?) Description: Starts the process of running tests in the assembly. ``` -------------------------------- ### Assert String Starts With (Custom Comparison) Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Verifies that a given string (`actualString`) starts with a specified substring (`expectedStartString`), allowing for a custom `StringComparison` type to be used. This provides flexibility for case-sensitive, culture-invariant, or ordinal comparisons. An exception is thrown if the `actualString` does not begin with the `expectedStartString` according to the specified comparison. ```C# public static void StartsWith(string? expectedStartString, string? actualString, StringComparison comparisonType) ``` ```APIDOC Method: StartsWith(string? expectedStartString, string? actualString, StringComparison comparisonType) Namespace: Xunit Assembly: xunit.v3.assert.dll Description: Verifies that a string starts with a ``` -------------------------------- ### FrontControllerLaunchOptions for xUnit.net Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index FrontControllerLaunchOptions in xUnit.net specifies launch options when using IFrontController and IFrontControllerDiscoverer, primarily for v3 test projects. ```C# /// /// Launch options when using IFrontController and/or IFrontControllerDiscoverer. Current only supported by v3 test projects (all options will be ignored for v1/v2 test projects). /// public class FrontControllerLaunchOptions ``` -------------------------------- ### Assert String Starts With (Current Culture) Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.Assert.StartsWith Verifies that a given string (`actualString`) starts with another specified string (`expectedStartString`), using the current culture's comparison rules. This assertion is typically used in unit tests to ensure string prefixes match as expected. An exception is thrown if the `actualString` does not begin with the `expectedStartString`. ```C# public static void StartsWith(string? expectedStartString, string? actualString) ``` ```APIDOC Method: StartsWith(string? expectedStartString, string? actualString) Namespace: Xunit Assembly: xunit.v3.assert.dll Description: Verifies that a string starts with a given string, using the current culture. Parameters: expectedStartString [string]: The string expected to be at the start of the string actualString [string]: The string to be inspected Exceptions: Thrown when the string does not start with the expected sub-string ``` -------------------------------- ### xUnit.net Before Method API Documentation Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.CaptureConsoleAttribute.Before Detailed API documentation for the 'Before' method in the Xunit namespace, including its assembly, purpose, and a description of its parameters. ```APIDOC Method: Before(MethodInfo, IXunitTest) Namespace: Xunit Assembly: xunit.v3.core.dll Description: This method is called before the test method is executed. Parameters: methodUnderTest: MethodInfo - The method under test test: IXunitTest - The current ITest ``` -------------------------------- ### GetXunitTestCaseDiscoverer(Type) API Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.ExtensibilityPointFactory Gets an xUnit.net v3 test discoverer instance. ```APIDOC GetXunitTestCaseDiscoverer(type: System.Type) Description: Gets an xUnit.net v3 test discoverer. ``` -------------------------------- ### GetMethodFactAttributes(MethodInfo) API Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.ExtensibilityPointFactory Gets the IFactAttributes attached to the given test method. ```APIDOC GetMethodFactAttributes(methodInfo: System.Reflection.MethodInfo) Description: Gets the IFactAttributes attached to the given test method. ``` -------------------------------- ### GetMethodDataAttributes(MethodInfo) API Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.ExtensibilityPointFactory Gets the IDataAttributes attached to the given test method. ```APIDOC GetMethodDataAttributes(methodInfo: System.Reflection.MethodInfo) Description: Gets the IDataAttributes attached to the given test method. ``` -------------------------------- ### TestPipelineStartupAttribute Constructor and Properties Source: https://api.xunit.net/v3/2.0.3/Xunit.html/index Describes the TestPipelineStartupAttribute class, used for configuring test pipeline startup behavior. Includes its constructor and the TestPipelineStartupType property. ```C# public sealed class TestPipelineStartupAttribute : Attribute { public TestPipelineStartupAttribute(Type testPipelineStartupType); public Type TestPipelineStartupType { get; } } ``` -------------------------------- ### GetMethodBeforeAfterTestAttributes(MethodInfo, IReadOnlyCollection) API Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.ExtensibilityPointFactory Gets the IBeforeAfterTestAttributes attached to the given method. ```APIDOC GetMethodBeforeAfterTestAttributes(methodInfo: System.Reflection.MethodInfo, beforeAfterTestAttributes: System.Collections.Generic.IReadOnlyCollection) Description: Gets the IBeforeAfterTestAttributes attached to the given method. ``` -------------------------------- ### APIDOC: Xunit.v3 Launch Method Source: https://api.xunit.net/v3/2.0.3/Xunit.html/v3.2.0.3-Xunit.v3.OutOfProcessTestProcessLauncherBase.Launch Comprehensive API documentation for the 'Launch' method in the Xunit.v3 namespace, detailing its assembly, purpose, parameters, and return type. ```APIDOC Method: Launch Namespace: Xunit.v3 Assembly: xunit.v3.runner.utility.netfx.dll Description: Launches the test process. Returns null if the process could not be launched. Signature: Launch(XunitProjectAssembly, IReadOnlyList) Parameters: projectAssembly: The test project assembly arguments (IReadOnlyList): The list of arguments to be passed to the in-process runner Returns: ITestProcess? ``` -------------------------------- ### GetXunitTestCollectionFactory(Type?, IXunitTestAssembly) API Source: https://api.xunit.net/v3/2.0.3/Xunit.html/Xunit.v3.ExtensibilityPointFactory Gets an xUnit.net v3 test collection factory instance. ```APIDOC GetXunitTestCollectionFactory(type: System.Type?, testAssembly: Xunit.v3.IXunitTestAssembly) Description: Gets an xUnit.net v3 test collection factory. ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.