Skip to main content

Definition

Assembly: CloudNimble.Breakdance.DotHttp.dll Namespace: CloudNimble.Breakdance.DotHttp Inheritance: CloudNimble.Breakdance.Assemblies.BreakdanceTestBase

Syntax

Summary

Base class for generated .http file tests. Provides HTTP client management, variable resolution, and response capture for request chaining.

Remarks

Inherits from BreakdanceTestBase for integration with the Breakdance testing framework. Generated test classes are partial, allowing customization of setup and assertions.

Examples

Methods

LoadEnvironment

Loads environment configuration from an http-client.env.json file.

Syntax

Parameters

NameTypeDescription
filePathstringThe path to the environment file.
environmentNamestringThe environment to use (e.g., “dev”, “staging”).

Examples

LoadEnvironmentWithOverrides

Loads environment configuration with user overrides.

Syntax

Parameters

NameTypeDescription
baseFilePathstringThe path to the http-client.env.json file.
userFilePathstringThe path to the http-client.env.json.user file.
environmentNamestringThe environment to use.

Examples

SetVariable

Sets a variable for use in request resolution.

Syntax

Parameters

NameTypeDescription
namestringThe variable name (without @ prefix or wrapper).
valuestringThe variable value.

Examples

SwitchEnvironment

Switches to a different environment from the loaded configuration.

Syntax

Parameters

NameTypeDescription
environmentNamestringThe environment name to switch to.

Examples

TestSetupAsync Override

Sets up the test environment.

Syntax

Returns

Type: System.Threading.Tasks.Task

TestTearDownAsync Override

Cleans up resources after each test.

Syntax

Returns

Type: System.Threading.Tasks.Task