parallel_report_portal 2.5.0 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bdb8752fe04d7457a3333f818ee74af105d17f1cb32ae0c6ecd8daa897d11f7f
|
4
|
+
data.tar.gz: ef6b77445231d20740f515f046c35fd39266361fd6637b524958907c974b8014
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 19864c308420494e6dd7c0cd6321fc53aaafba70b1fe6d0ea0caf9957c69b308aaf9034e1c48551d4a06ae2580c827975489dcf6d22f5523d13c251bb966dce6
|
7
|
+
data.tar.gz: c70a9b840d9d9cb2e2b1ecb071d6b2ff65e5479faacdea9bcf2307cc4edde7d8f768e4cbde5d18fadd7e4d637ed2a50fe6ba0483031cb68bb869a4d34b521532
|
data/README.md
CHANGED
@@ -46,7 +46,7 @@ read_timeout: 60
|
|
46
46
|
|
47
47
|
It will search for the following environment variables which may be in upper or lowercase (the official client defers to lower case, this is available here for compatibility).
|
48
48
|
|
49
|
-
- `
|
49
|
+
- `REPORT_PORTAL_API_KEY` - the API Key for this Report Portal instance which must be created in advance
|
50
50
|
- `RP_ENDPOINT` - the endpoint for this Report Portal instance
|
51
51
|
- `RP_PROJECT` - the Report Portal project name which must be created in advance and this user added as a member
|
52
52
|
- `RP_LAUNCH` - the name of this 'launch'
|
@@ -14,7 +14,7 @@ module ParallelReportPortal
|
|
14
14
|
#
|
15
15
|
# == Environment variables
|
16
16
|
#
|
17
|
-
#
|
17
|
+
# REPORT_PORTAL_API_KEY:: The API key required for authentication
|
18
18
|
# RP_ENDPOINT:: the URL of the Report Portal API endpoint
|
19
19
|
# RP_PROJECT:: the Report Portal project name -- this must already exist within Report Port and this user must be a member of the project
|
20
20
|
# RP_LAUNCH:: The name of this launch
|
@@ -22,10 +22,10 @@ module ParallelReportPortal
|
|
22
22
|
# RP_TAGS:: A set of tags to pass to Report Portal for this launch. If these are set via an environment variable, provide a comma-separated string of tags
|
23
23
|
# RP_ATTRIBUTES:: A set of attribute tags to pass to Report Portal for this launch. If these are set via an environment variable, provide a comma-separated string of attributes
|
24
24
|
class Configuration
|
25
|
-
ATTRIBUTES = [:
|
25
|
+
ATTRIBUTES = [:api_key, :endpoint, :project, :launch, :debug, :description, :tags, :attributes, :open_timeout, :idle_timeout, :read_timeout]
|
26
26
|
|
27
|
-
# @return [String] the Report Portal
|
28
|
-
attr_accessor :
|
27
|
+
# @return [String] the Report Portal API key required for authorization
|
28
|
+
attr_accessor :api_key
|
29
29
|
# @return [String] the Report Portal URI - this should include the scheme
|
30
30
|
# e.g. +https://reportportal.local/api/v1+
|
31
31
|
attr_accessor :endpoint
|
@@ -56,14 +56,21 @@ module ParallelReportPortal
|
|
56
56
|
#
|
57
57
|
# The initializer will first attempt to load a configuration files called
|
58
58
|
# +report_portal.yml+ (case insensitive) in the both the +config+ and current
|
59
|
-
# working directory (the former takes
|
59
|
+
# working directory (the former takes precedence). It will then apply
|
60
60
|
# any of the environment variable values.
|
61
61
|
def initialize
|
62
62
|
load_configuration_file
|
63
63
|
ATTRIBUTES.each do |attr|
|
64
|
-
env_value = get_env("rp_#{attr.to_s}")
|
64
|
+
env_value = get_env("rp_#{attr.to_s}") || get_env("report_portal_#{attr.to_s}")
|
65
65
|
send(:"#{attr}=", env_value) if env_value
|
66
66
|
end
|
67
|
+
|
68
|
+
# If this is compiled against OpenSSL v3, we need to turn off the exception raising
|
69
|
+
# when the server closes the stream without sending an EOF message in advance
|
70
|
+
if OpenSSL::SSL.const_defined?(:OP_IGNORE_UNEXPECTED_EOF)
|
71
|
+
# Assign the additional parameter with a bitwise 'or' assignment
|
72
|
+
OpenSSL::SSL::SSLContext::DEFAULT_PARAMS[:options] |= OpenSSL::SSL::OP_IGNORE_UNEXPECTED_EOF
|
73
|
+
end
|
67
74
|
end
|
68
75
|
|
69
76
|
# Sets the tags for the launch. If an array is provided, the array is used,
|
@@ -146,6 +153,8 @@ module ParallelReportPortal
|
|
146
153
|
ATTRIBUTES.each do |attr|
|
147
154
|
yaml_key = if yaml.has_key?("rp_#{attr}".to_sym)
|
148
155
|
"rp_#{attr}".to_sym
|
156
|
+
elsif yaml.has_key?("report_portal_#{attr}".to_sym)
|
157
|
+
"report_portal_#{attr}".to_sym
|
149
158
|
else
|
150
159
|
attr
|
151
160
|
end
|
@@ -1,5 +1,6 @@
|
|
1
1
|
require 'logger'
|
2
2
|
require 'tempfile'
|
3
|
+
require 'pry'
|
3
4
|
|
4
5
|
module ParallelReportPortal
|
5
6
|
# A collection of methods for communicating with the ReportPortal
|
@@ -22,7 +23,7 @@ module ParallelReportPortal
|
|
22
23
|
#
|
23
24
|
# @return [String] header the bearer header value
|
24
25
|
def authorization_header
|
25
|
-
"Bearer #{ParallelReportPortal.configuration.
|
26
|
+
"Bearer #{ParallelReportPortal.configuration.api_key}"
|
26
27
|
end
|
27
28
|
|
28
29
|
# Get a preconstructed Faraday HTTP connection
|
@@ -81,7 +82,11 @@ module ParallelReportPortal
|
|
81
82
|
mode: (ParallelReportPortal.configuration.debug ? 'DEBUG' : 'DEFAULT' ),
|
82
83
|
attributes: ParallelReportPortal.configuration.attributes
|
83
84
|
}.to_json
|
84
|
-
|
85
|
+
end
|
86
|
+
|
87
|
+
pp "#########################"
|
88
|
+
pp resp
|
89
|
+
|
85
90
|
if resp.success?
|
86
91
|
JSON.parse(resp.body)['id']
|
87
92
|
else
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: parallel_report_portal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 3.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nigel Brookes-Thomas
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2023-
|
12
|
+
date: 2023-12-21 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: appraisal
|
@@ -255,7 +255,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
255
255
|
- !ruby/object:Gem::Version
|
256
256
|
version: '0'
|
257
257
|
requirements: []
|
258
|
-
rubygems_version: 3.
|
258
|
+
rubygems_version: 3.2.3
|
259
259
|
signing_key:
|
260
260
|
specification_version: 4
|
261
261
|
summary: Run Cucumber Tests in parallel and with Cucumber 3 and 4+
|