elasticsearch-test-runner 0.3.0 โ 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/elasticsearch/tests/printer.rb +6 -3
- data/lib/elasticsearch/tests/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 371dabd8cff033ef7d2656b874f4fcb5fd63f5bde3093d5ce1ee830e9e253187
|
4
|
+
data.tar.gz: 43006ff9d74aea61684af8abc8e660099c009a1e7293d489c5796887efb9756e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b927b0015746d72b19d26ac3812243f4b91df653d785b924a58a8dd219608358ed1e3dbbf6b76af3ce240b4d3289371ded4615e38f8d891438b929311b9abe77
|
7
|
+
data.tar.gz: a5b2ef6724092c8d6d4a39893346d233ca2c170121d59778ef4f85fea66e339e4db33ccfe40deac23d1d9b4f55dc306ffaa7c4ad5ba4bee8288b53887870b3b6
|
data/CHANGELOG.md
CHANGED
@@ -34,18 +34,21 @@ module Elasticsearch
|
|
34
34
|
def print_failure(action, response)
|
35
35
|
puts "๐ด #{@file} #{@title} failed"
|
36
36
|
puts "Expected result: #{action}" # TODO: Show match/length differently
|
37
|
-
if
|
37
|
+
if defined?(ElasticsearchServerless) &&
|
38
|
+
response.is_a?(ElasticsearchServerless::API::Response) ||
|
39
|
+
defined?(Elasticsearch::API) && response.is_a?(Elasticsearch::API::Response)
|
38
40
|
puts 'Response:'
|
39
41
|
pp response.body
|
40
42
|
else
|
41
43
|
pp response
|
42
44
|
end
|
43
|
-
raise Elasticsearch::Tests::ActionError.new(
|
45
|
+
raise Elasticsearch::Tests::ActionError.new(response.body, @file, action)
|
44
46
|
end
|
45
47
|
|
46
48
|
def print_match_failure(action)
|
47
49
|
keys = action['match'].keys.first
|
48
50
|
value = action['match'].values.first
|
51
|
+
|
49
52
|
message = <<~MSG
|
50
53
|
๐ด #{@file} #{@title} failed
|
51
54
|
Expected: { #{keys}: #{value} }
|
@@ -66,7 +69,7 @@ module Elasticsearch
|
|
66
69
|
puts "+++ โ Errors/Failures: #{errors.count}"
|
67
70
|
errors.map do |error|
|
68
71
|
puts "๐งช Test: #{error[:file]}"
|
69
|
-
puts "โถ Action: #{error[:action]
|
72
|
+
puts "โถ Action: #{error[:action].first}" if error[:action]
|
70
73
|
puts "๐ฌ #{error[:error].message}"
|
71
74
|
pp error[:error].backtrace.join("$/\n") if ENV['DEBUG']
|
72
75
|
puts
|