OpenTelemetry PHP

ResourceInfoTest extends TestCase
in package
uses TestState

Attributes
#[CoversClass]
\OpenTelemetry\SDK\Resource\ResourceInfo::class

Table of Contents

Properties

$environmentVariables  : array<string|int, mixed>

Methods

differentResourcesProvider()  : iterable<string|int, mixed>
sameResourcesProvider()  : iterable<string|int, mixed>
schemaUrlsToMergeProvider()  : Generator
setUp()  : void
test_get_attributes()  : void
test_merge()  : void
test_merge_schema_url()  : void
test_merge_uses_value_of_updating_resource()  : void
"If a key exists on both the old and updating resource, the value of the updating resource MUST be picked (even if the updated value is empty)"
test_merge_with_numeric_attribute_keys()  : void
test_serialize_incorporates_all_properties()  : void
test_serialize_returns_different_output_for_objects_representing_different_resources()  : void
test_serialize_returns_same_output_for_objects_representing_the_same_resource()  : void
restoreEnvironmentVariables()  : void
setEnvironmentVariable()  : void
tearDownSharedState()  : void

Properties

$environmentVariables

private array<string|int, mixed> $environmentVariables = []

Methods

differentResourcesProvider()

public static differentResourcesProvider() : iterable<string|int, mixed>
Return values
iterable<string|int, mixed>

sameResourcesProvider()

public static sameResourcesProvider() : iterable<string|int, mixed>
Return values
iterable<string|int, mixed>

schemaUrlsToMergeProvider()

public static schemaUrlsToMergeProvider() : Generator
Return values
Generator

test_merge_schema_url()

public test_merge_schema_url(array<string|int, mixed> $schemaUrlsToMerge, string|null $expectedSchemaUrl) : void
Parameters
$schemaUrlsToMerge : array<string|int, mixed>
$expectedSchemaUrl : string|null
Attributes
#[DataProvider]
'schemaUrlsToMergeProvider'

test_merge_uses_value_of_updating_resource()

"If a key exists on both the old and updating resource, the value of the updating resource MUST be picked (even if the updated value is empty)"

public test_merge_uses_value_of_updating_resource() : void
Attributes
#[Group]
'compliance'

test_merge_with_numeric_attribute_keys()

public test_merge_with_numeric_attribute_keys() : void

test_serialize_incorporates_all_properties()

public test_serialize_incorporates_all_properties() : void

test_serialize_returns_different_output_for_objects_representing_different_resources()

public test_serialize_returns_different_output_for_objects_representing_different_resources(ResourceInfo $resource1, ResourceInfo $resource2) : void
Parameters
$resource1 : ResourceInfo
$resource2 : ResourceInfo
Attributes
#[DataProvider]
'differentResourcesProvider'

test_serialize_returns_same_output_for_objects_representing_the_same_resource()

public test_serialize_returns_same_output_for_objects_representing_the_same_resource(ResourceInfo $resource1, ResourceInfo $resource2) : void
Parameters
$resource1 : ResourceInfo
$resource2 : ResourceInfo
Attributes
#[DataProvider]
'sameResourcesProvider'

restoreEnvironmentVariables()

protected restoreEnvironmentVariables() : void
Attributes
#[After]

setEnvironmentVariable()

protected setEnvironmentVariable(string $variable, mixed $value) : void
Parameters
$variable : string
$value : mixed

tearDownSharedState()

protected tearDownSharedState() : void
Attributes
#[After]

        
On this page

Search results