sig/datadog/ci/test_visibility/serializers/base.rbs in datadog-ci-0.4.1 vs sig/datadog/ci/test_visibility/serializers/base.rbs in datadog-ci-0.5.0
- old
+ new
@@ -5,22 +5,32 @@
class Base
MINIMUM_TIMESTAMP_NANO: 946684800000000000
MINIMUM_DURATION_NANO: 0
MAXIMUM_DURATION_NANO: 9223372036854775807
+ CONTENT_FIELDS: Array[String | Hash[String, String]]
+ REQUIRED_FIELDS: Array[String]
+
@content_fields_count: Integer
@start: Integer
@duration: Integer
+ @meta: Hash[untyped, untyped]
+ @errors: Hash[String, Set[String]]
+ @validated: bool
attr_reader trace: Datadog::Tracing::TraceSegment
attr_reader span: Datadog::Tracing::Span
+ attr_reader meta: Hash[untyped, untyped]
def initialize: (Datadog::Tracing::TraceSegment trace, Datadog::Tracing::Span span) -> void
def to_msgpack: (?untyped? packer) -> untyped
def valid?: () -> bool
+ def validate!: () -> void
+ def validation_errors: () -> Hash[String, Set[String]]
+
def content_fields: () -> ::Array[String | Hash[String, String]]
def content_map_size: () -> Integer
def runtime_id: () -> String
@@ -28,10 +38,16 @@
def span_id: () -> String
def parent_id: () -> String
+ def test_session_id: () -> Integer?
+
+ def test_module_id: () -> Integer?
+
+ def test_suite_id: () -> Integer?
+
def type: () -> nil
def version: () -> 1
def span_type: () -> String
@@ -44,27 +60,32 @@
def start: () -> Integer
def duration: () -> Integer
- def meta: () -> Hash[String, untyped]
-
def metrics: () -> Hash[String, untyped]
def error: () -> Integer
def self.calculate_content_map_size: (Array[String | Hash[String, String]] fields_list) -> Integer
private
- def valid_start_time?: () -> bool
- def valid_duration?: () -> bool
- def required_fields_present?: () -> bool
+ def validate_start_time!: () -> void
+ def validate_duration!: () -> void
+ def validate_required_fields!: () -> void
+ def validate_required!: (String field) -> void
+ def validate_greater_than_or_equal!: (String field, Integer value) -> void
+ def validate_less_than_or_equal!: (String field, Integer value) -> void
+ def add_error: (String field, String message) -> void
+
def required_fields: () -> Array[String]
def write_field: (untyped packer, String field_name, ?String? method) -> untyped
def time_nano: (Time time) -> Integer
def duration_nano: (Float duration) -> Integer
+
+ def to_integer: (String? value) -> Integer?
def content_fields_count: () -> Integer
end
end
end