bugsnag-maze-runner 8.7.0 → 8.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/maze/bugsnag_config.rb +1 -0
- data/lib/maze/client/appium/bb_client.rb +4 -3
- data/lib/maze/client/appium/bb_devices.rb +14 -20
- data/lib/maze/client/appium/bs_devices.rb +4 -0
- data/lib/maze/client/selenium/bs_browsers.yml +6 -0
- data/lib/maze/driver/appium.rb +1 -2
- data/lib/maze/servlets/log_servlet.rb +1 -1
- data/lib/maze/servlets/reflective_servlet.rb +1 -1
- data/lib/maze/servlets/servlet.rb +5 -4
- data/lib/maze.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2a388bfd92b4320dcb3ea1274139bec642ae20bde1444308db69e8ea02b34702
|
4
|
+
data.tar.gz: f76f9d26694701e431b4e9bcf7392d585472a5965b493d00f7894017ebcf7e31
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6528c4ed3c228fc2e84270f085ea5630a64c8d9ee1931d23d815c831a1a608b3c078c496041c886096118f785b75ef92dcc9d07b19c3a06e18c3d2e827554a00
|
7
|
+
data.tar.gz: 498cf85f7cdd5b42023e667428fcf3347a317895c994bd5df09958cdcbeb9d99f06245c7400ef09cd5f256f7f8e30d7bc4b4a12270e8f514e6cebedf743a44bf
|
data/lib/maze/bugsnag_config.rb
CHANGED
@@ -10,6 +10,7 @@ module Maze
|
|
10
10
|
|
11
11
|
Bugsnag.configure do |config|
|
12
12
|
config.api_key = ENV['MAZE_BUGSNAG_API_KEY']
|
13
|
+
config.app_version = Maze::VERSION
|
13
14
|
config.discard_classes << 'Test::Unit::AssertionFailedError'
|
14
15
|
config.add_metadata(:'test driver', {
|
15
16
|
'driver type': Maze.driver.class,
|
@@ -30,10 +30,11 @@ module Maze
|
|
30
30
|
|
31
31
|
def device_capabilities
|
32
32
|
config = Maze.config
|
33
|
-
prefix = BitBarDevices.caps_prefix(config.appium_version)
|
34
33
|
capabilities = {
|
35
|
-
|
36
|
-
|
34
|
+
'appium:options' => {
|
35
|
+
'noReset' => true,
|
36
|
+
'newCommandTimeout' => 600
|
37
|
+
},
|
37
38
|
'bitbar:options' => {
|
38
39
|
# Some capabilities probably belong in the top level
|
39
40
|
# of the hash, but BitBar picks them up from here.
|
@@ -41,18 +41,11 @@ module Maze
|
|
41
41
|
Maze.config.os = platform
|
42
42
|
Maze.config.os_version = platform_version.to_f.floor
|
43
43
|
|
44
|
-
prefix = caps_prefix(Maze.config.appium_version)
|
45
|
-
|
46
44
|
case platform
|
47
45
|
when 'android'
|
48
|
-
|
49
|
-
'UiAutomator1'
|
50
|
-
else
|
51
|
-
'UiAutomator2'
|
52
|
-
end
|
53
|
-
make_android_hash(device_name, automation_name, prefix)
|
46
|
+
make_android_hash(device_name)
|
54
47
|
when 'ios'
|
55
|
-
make_ios_hash(device_name
|
48
|
+
make_ios_hash(device_name)
|
56
49
|
else
|
57
50
|
throw "Invalid device platform specified #{platform}"
|
58
51
|
end
|
@@ -98,34 +91,35 @@ module Maze
|
|
98
91
|
end
|
99
92
|
end
|
100
93
|
|
101
|
-
def make_android_hash(device
|
94
|
+
def make_android_hash(device)
|
102
95
|
hash = {
|
103
|
-
'automationName' => automation_name,
|
104
96
|
'platformName' => 'Android',
|
105
97
|
'deviceName' => 'Android Phone',
|
98
|
+
'appium:options' => {
|
99
|
+
'automationName' => 'UiAutomator2',
|
100
|
+
'autoGrantPermissions' => true,
|
101
|
+
'uiautomator2ServerInstallTimeout' => 60000
|
102
|
+
},
|
106
103
|
'bitbar:options' => {
|
107
|
-
"#{prefix}autoGrantPermissions" => true,
|
108
104
|
'device' => device,
|
109
105
|
}
|
110
106
|
}
|
111
107
|
hash.freeze
|
112
108
|
end
|
113
109
|
|
114
|
-
def make_ios_hash(device
|
110
|
+
def make_ios_hash(device)
|
115
111
|
{
|
116
|
-
'automationName' => 'XCUITest',
|
117
|
-
'deviceName' => 'iPhone device',
|
118
112
|
'platformName' => 'iOS',
|
119
|
-
|
113
|
+
'deviceName' => 'iPhone device',
|
114
|
+
'appium:options' => {
|
115
|
+
'automationName' => 'XCUITest',
|
116
|
+
'shouldTerminateApp' => 'true'
|
117
|
+
},
|
120
118
|
'bitbar:options' => {
|
121
119
|
'device' => device
|
122
120
|
}
|
123
121
|
}.freeze
|
124
122
|
end
|
125
|
-
|
126
|
-
def caps_prefix(appium_version)
|
127
|
-
appium_version.nil? || (appium_version.to_i >= 2) ? 'appium:' : ''
|
128
|
-
end
|
129
123
|
end
|
130
124
|
end
|
131
125
|
end
|
@@ -79,6 +79,7 @@ module Maze
|
|
79
79
|
'ANDROID_7' => make_android_hash('Google Pixel', '7.1'),
|
80
80
|
|
81
81
|
# iOS devices
|
82
|
+
'IOS_17' => make_ios_hash('iPhone 15', '17'),
|
82
83
|
'IOS_16' => make_ios_hash('iPhone 14', '16'),
|
83
84
|
'IOS_15' => make_ios_hash('iPhone 11 Pro', '15'),
|
84
85
|
'IOS_14' => make_ios_hash('iPhone 11', '14'),
|
@@ -110,6 +111,9 @@ module Maze
|
|
110
111
|
add_android 'Samsung Galaxy S8', '7.0', hash # ANDROID_7_0_SAMSUNG_GALAXY_S8
|
111
112
|
|
112
113
|
# Specific iOS devices
|
114
|
+
add_ios 'iPhone 15', '17.0', hash # IOS_17_0_IPHONE_15
|
115
|
+
add_ios 'iPhone 12 Pro', '17.0', hash # IOS_17_0_IPHONE_12_PRO
|
116
|
+
|
113
117
|
add_ios 'iPhone 14 Plus', '16.0', hash # IOS_16_0_IPHONE_14_PLUS
|
114
118
|
add_ios 'iPhone 14 Pro', '16.0', hash # IOS_16_0_IPHONE_14_PRO
|
115
119
|
add_ios 'iPhone 14 Pro Max', '16.0', hash # IOS_16_0_IPHONE_14_PRO_MAX
|
data/lib/maze/driver/appium.rb
CHANGED
@@ -57,10 +57,9 @@ module Maze
|
|
57
57
|
super
|
58
58
|
$logger.info "Appium driver started in #{(Time.now - time).to_i}s"
|
59
59
|
rescue => error
|
60
|
-
Bugsnag.notify(error)
|
61
|
-
|
62
60
|
$logger.warn "Appium driver failed to start in #{(Time.now - time).to_i}s"
|
63
61
|
$logger.warn "#{error.class} occurred with message: #{error.message}"
|
62
|
+
# Do not Bugsnag.notify here as we re-raise the error
|
64
63
|
raise error
|
65
64
|
end
|
66
65
|
end
|
@@ -102,9 +102,9 @@ module Maze
|
|
102
102
|
set_response_header response.header
|
103
103
|
response.status = post_status_code
|
104
104
|
rescue JSON::ParserError => e
|
105
|
-
Bugsnag.notify e
|
106
105
|
msg = "Unable to parse request as JSON: #{e.message}"
|
107
106
|
if Maze.config.captured_invalid_requests.include? @request_type
|
107
|
+
Bugsnag.notify e
|
108
108
|
$logger.error msg
|
109
109
|
Server.invalid_requests.add({
|
110
110
|
reason: msg,
|
@@ -115,9 +115,10 @@ module Maze
|
|
115
115
|
$logger.warn msg
|
116
116
|
end
|
117
117
|
rescue StandardError => e
|
118
|
-
|
118
|
+
msg = "Invalid #{@request_type} request: #{e.message}"
|
119
119
|
if Maze.config.captured_invalid_requests.include? @request_type
|
120
|
-
|
120
|
+
Bugsnag.notify e
|
121
|
+
$logger.msg
|
121
122
|
Server.invalid_requests.add({
|
122
123
|
invalid: true,
|
123
124
|
reason: e.message,
|
@@ -128,7 +129,7 @@ module Maze
|
|
128
129
|
}
|
129
130
|
})
|
130
131
|
else
|
131
|
-
$logger.warn
|
132
|
+
$logger.warn msg
|
132
133
|
end
|
133
134
|
end
|
134
135
|
|
data/lib/maze.rb
CHANGED
@@ -7,7 +7,7 @@ require_relative 'maze/timers'
|
|
7
7
|
# Glues the various parts of MazeRunner together that need to be accessed globally,
|
8
8
|
# providing an alternative to the proliferation of global variables or singletons.
|
9
9
|
module Maze
|
10
|
-
VERSION = '8.
|
10
|
+
VERSION = '8.8.0'
|
11
11
|
|
12
12
|
class << self
|
13
13
|
attr_accessor :check, :driver, :internal_hooks, :mode, :start_time, :dynamic_retry, :public_address,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bugsnag-maze-runner
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 8.
|
4
|
+
version: 8.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Steve Kirkland
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-10-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cucumber
|