Skip to content

Commit

Permalink
Fix yml test
Browse files Browse the repository at this point in the history
  • Loading branch information
felixbarny committed Jul 30, 2024
1 parent e39050b commit b2cb955
Showing 1 changed file with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1105,14 +1105,18 @@ non string dimension fields:
match_mapping_type: boolean
mapping:
type: keyword
- double_as_double:
match_mapping_type: double
mapping:
type: double

- do:
bulk:
index: k9s
refresh: true
body:
- '{ "create": { "dynamic_templates": { "metrics.data": "counter_metric" } } }'
- '{ "@timestamp": "2023-09-01T13:03:08.138Z", "metrics.data": "10", "attributes.string": "foo", "attributes.boolean": true, "attributes.integer": 1, "attributes.float": 1.1, "attributes.host.ip": "127.0.0.1" }'
- '{ "@timestamp": "2023-09-01T13:03:08.138Z", "metrics.data": "10", "attributes.string": "foo", "attributes.boolean": true, "attributes.integer": 1, "attributes.double": 1.1, "attributes.host.ip": "127.0.0.1" }'
- is_false: errors

- do:
Expand All @@ -1132,7 +1136,7 @@ non string dimension fields:
attributes.integer:
value: 1
- term:
attributes.float:
attributes.double:
value: 1.1
- term:
attributes.host.ip:
Expand All @@ -1143,7 +1147,7 @@ non string dimension fields:
- match: { hits.hits.0.fields.attributes\.string: [ "foo" ] }
- match: { hits.hits.0.fields.attributes\.boolean: [ "true" ] }
- match: { hits.hits.0.fields.attributes\.integer: [ 1 ] }
- match: { hits.hits.0.fields.attributes\.float: [ 1.1 ] }
- match: { hits.hits.0.fields.attributes\.double: [ 1.1 ] }
- match: { hits.hits.0.fields.attributes\.host\.ip: [ "127.0.0.1" ] }

- do:
Expand All @@ -1158,5 +1162,5 @@ non string dimension fields:
- match: { .$idx0name.mappings.properties.attributes.properties.string.type: 'keyword' }
- match: { .$idx0name.mappings.properties.attributes.properties.boolean.type: 'keyword' }
- match: { .$idx0name.mappings.properties.attributes.properties.integer.type: 'long' }
- match: { .$idx0name.mappings.properties.attributes.properties.float.type: 'float' }
- match: { .$idx0name.mappings.properties.attributes.properties.double.type: 'double' }
- match: { .$idx0name.mappings.properties.attributes.properties.host\.ip.type: 'ip' }

0 comments on commit b2cb955

Please sign in to comment.