SamplerFactoryTest
extends TestCase
uses
TestState
-
#[CoversClass]
-
\OpenTelemetry\SDK\Trace\SamplerFactory::class
Table of Contents
Properties
-
$environmentVariables
: array<string|int, mixed>
Methods
-
invalidSamplerProvider()
: array<string|int, mixed>
-
samplerProvider()
: array<string|int, mixed>
-
test_create_sampler_from_environment()
: void
-
test_throws_exception_for_invalid_or_unsupported()
: void
-
restoreEnvironmentVariables()
: void
-
setEnvironmentVariable()
: void
-
tearDownSharedState()
: void
$environmentVariables
private
array<string|int, mixed>
$environmentVariables
= []
invalidSamplerProvider()
public
static invalidSamplerProvider() : array<string|int, mixed>
Return values
array<string|int, mixed>
samplerProvider()
public
static samplerProvider() : array<string|int, mixed>
Return values
array<string|int, mixed>
test_create_sampler_from_environment()
public
test_create_sampler_from_environment(string $samplerName, string $expected[, string|null $arg = null ]) : void
Parameters
-
$samplerName
: string
-
-
$expected
: string
-
-
$arg
: string|null
= null
-
-
#[DataProvider]
-
'samplerProvider'
test_throws_exception_for_invalid_or_unsupported()
public
test_throws_exception_for_invalid_or_unsupported(string|null $sampler[, string|null $arg = null ]) : void
Parameters
-
$sampler
: string|null
-
-
$arg
: string|null
= null
-
-
#[DataProvider]
-
'invalidSamplerProvider'
restoreEnvironmentVariables()
protected
restoreEnvironmentVariables() : void
setEnvironmentVariable()
protected
setEnvironmentVariable(string $variable, mixed $value) : void
Parameters
-
$variable
: string
-
-
$value
: mixed
-
tearDownSharedState()
protected
tearDownSharedState() : void