Class: Datadog::CI::TestVisibility::Serializers::TestV1
- Inherits:
-
Base
- Object
- Base
- Datadog::CI::TestVisibility::Serializers::TestV1
show all
- Defined in:
- lib/datadog/ci/test_visibility/serializers/test_v1.rb
Constant Summary
collapse
- CONTENT_FIELDS =
[
"trace_id", "span_id",
"name", "resource", "service",
"error", "start", "duration",
"meta", "metrics",
"type" => "span_type"
].freeze
- CONTENT_MAP_SIZE =
calculate_content_map_size(CONTENT_FIELDS)
- REQUIRED_FIELDS =
[
"trace_id",
"span_id",
"error",
"name",
"resource",
"start",
"duration"
].freeze
Constants inherited
from Base
Base::MAXIMUM_DURATION_NANO, Base::MINIMUM_DURATION_NANO, Base::MINIMUM_TIMESTAMP_NANO
Instance Attribute Summary
Attributes inherited from Base
#span, #trace
Instance Method Summary
collapse
Methods inherited from Base
calculate_content_map_size, #duration, #error, #initialize, #meta, #metrics, #parent_id, #runtime_id, #service, #span_id, #span_type, #start, #to_msgpack, #trace_id, #valid?, #version
Instance Method Details
#content_fields ⇒ Object
31
32
33
|
# File 'lib/datadog/ci/test_visibility/serializers/test_v1.rb', line 31
def content_fields
CONTENT_FIELDS
end
|
#content_map_size ⇒ Object
35
36
37
|
# File 'lib/datadog/ci/test_visibility/serializers/test_v1.rb', line 35
def content_map_size
CONTENT_MAP_SIZE
end
|
#name ⇒ Object
43
44
45
|
# File 'lib/datadog/ci/test_visibility/serializers/test_v1.rb', line 43
def name
"#{@span.get_tag(Ext::Test::TAG_FRAMEWORK)}.test"
end
|
#resource ⇒ Object
47
48
49
|
# File 'lib/datadog/ci/test_visibility/serializers/test_v1.rb', line 47
def resource
"#{@span.get_tag(Ext::Test::TAG_SUITE)}.#{@span.get_tag(Ext::Test::TAG_NAME)}"
end
|
#type ⇒ Object
39
40
41
|
# File 'lib/datadog/ci/test_visibility/serializers/test_v1.rb', line 39
def type
"test"
end
|