ruby_raider 1.0.7 → 1.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/generators/automation/templates/partials/android_caps.tt +11 -1
- data/lib/generators/automation/templates/partials/cross_platform_caps.tt +10 -0
- data/lib/generators/automation/templates/partials/ios_caps.tt +11 -1
- data/lib/generators/templates/helpers/partials/driver_and_options.tt +57 -11
- data/lib/version +1 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 03e16c261b9124a0b9a33227e4e60734cd9c8fd53891a5c2857427d11d6073e5
|
4
|
+
data.tar.gz: 410e1198dae7af2d0a3a7a94f512b5105a591b2e2b580360265d3aa7e06812fa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c3bf4f0c02db69267c4d58b1caa74e9c755aa2ba791207a0671ef496c550a7cef3033e06f5f7088ca53453b4030c4f4806592fc7c248dc8df7d85d3b0f7182ca
|
7
|
+
data.tar.gz: 001e01e21e63625abba1ad2e88f92e588f30555ae2bacd2b7a86d6b6434abea6470167402bc918dc7cbfa419dcde08ebb69937c8f5c83d3a813d2924960c2f7e
|
@@ -4,4 +4,14 @@ appium:options:
|
|
4
4
|
platformVersion: '12'
|
5
5
|
automationName: UiAutomator2
|
6
6
|
deviceName: Pixel 3 API 32
|
7
|
-
app: Android-MyDemoAppRN.1.3.0.build-244.apk
|
7
|
+
app: Android-MyDemoAppRN.1.3.0.build-244.apk
|
8
|
+
|
9
|
+
browserstack:
|
10
|
+
platformName: Android
|
11
|
+
os_version: '9.0'
|
12
|
+
deviceName: Google Pixel 3
|
13
|
+
app: bs://044a22528dfcf4ceaa1b0b31fb574d5010aabb91
|
14
|
+
browserstack.user: <%= ENV['BROWSERSTACK_USER'] %>
|
15
|
+
browserstack.key: <%= ENV['BROWSERSTACK_KEY'] %>
|
16
|
+
project: 'MyDemoAppRN'
|
17
|
+
name: 'MyDemoAppRN-Android'
|
@@ -13,3 +13,13 @@ ios:
|
|
13
13
|
automationName: XCUITest
|
14
14
|
app: MyRNDemoApp.app
|
15
15
|
autoDismissAlerts: true
|
16
|
+
|
17
|
+
browserstack:
|
18
|
+
platformName: Android
|
19
|
+
os_version: '9.0'
|
20
|
+
deviceName: Google Pixel 3
|
21
|
+
app: bs://044a22528dfcf4ceaa1b0b31fb574d5010aabb91
|
22
|
+
browserstack.user: <%= ENV['BROWSERSTACK_USER'] %>
|
23
|
+
browserstack.key: <%= ENV['BROWSERSTACK_KEY'] %>
|
24
|
+
project: 'MyDemoAppRN'
|
25
|
+
name: 'MyDemoAppRN-Android'
|
@@ -5,4 +5,14 @@ appium:options:
|
|
5
5
|
deviceName: iPhone 15
|
6
6
|
automationName: XCUITest
|
7
7
|
app: MyRNDemoApp.app
|
8
|
-
autoDismissAlerts: true
|
8
|
+
autoDismissAlerts: true
|
9
|
+
|
10
|
+
browserstack:
|
11
|
+
platformName: iOS
|
12
|
+
os_version: '17.5.1'
|
13
|
+
deviceName: iPhone 15
|
14
|
+
app: bs://044a22528dfcf4ceaa1b0b31fb574d5010aabb91
|
15
|
+
browserstack.user: <%= ENV['BROWSERSTACK_USER'] %>
|
16
|
+
browserstack.key: <%= ENV['BROWSERSTACK_KEY'] %>
|
17
|
+
project: 'MyDemoAppRN'
|
18
|
+
name: 'MyDemoAppRN-IOS'
|
@@ -31,7 +31,7 @@
|
|
31
31
|
end
|
32
32
|
<% elsif cross_platform? -%>
|
33
33
|
def create_driver
|
34
|
-
@driver =
|
34
|
+
@driver = configure_driver
|
35
35
|
end
|
36
36
|
|
37
37
|
def platform
|
@@ -51,19 +51,65 @@
|
|
51
51
|
def parse_app_path(path)
|
52
52
|
File.expand_path(path, Dir.pwd)
|
53
53
|
end
|
54
|
-
|
55
|
-
def
|
56
|
-
|
54
|
+
|
55
|
+
def browserstack?
|
56
|
+
ENV['TEST_ENV'] == 'browserstack'
|
57
57
|
end
|
58
58
|
|
59
|
-
|
60
|
-
|
61
|
-
caps = YAML.load_file('config/capabilities.yml')
|
62
|
-
caps['appium:options']['app'] = app_path(caps['appium:options']['app'])
|
63
|
-
caps
|
59
|
+
def browserstack_caps
|
60
|
+
@browserstack_caps ||= YAML.load_file('config/capabilities.yml')['browserstack']
|
64
61
|
end
|
65
62
|
|
66
|
-
def
|
67
|
-
|
63
|
+
def configure_driver
|
64
|
+
if browserstack?
|
65
|
+
Appium::Driver.new({ caps: browserstack_caps,
|
66
|
+
'appium_lib': { server_url: parsed_browserstack_url}}, true)
|
67
|
+
else
|
68
|
+
Appium::Driver.new({ caps: parsed_caps })
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
def parsed_browserstack_url
|
73
|
+
username = ENV['BROWSERSTACK_USER']
|
74
|
+
access_key = ENV['BROWSERSTACK_KEY']
|
75
|
+
"https://#{username}:#{access_key}@hub-cloud.browserstack.com/wd/hub"
|
68
76
|
end
|
77
|
+
<% else -%>
|
78
|
+
def create_driver
|
79
|
+
@driver = configure_driver
|
80
|
+
end
|
81
|
+
|
82
|
+
# :reek:UtilityFunction
|
83
|
+
def parsed_caps
|
84
|
+
caps = YAML.load_file('config/capabilities.yml')
|
85
|
+
caps['appium:options']['app'] = app_path(caps['appium:options']['app'])
|
86
|
+
caps
|
87
|
+
end
|
88
|
+
|
89
|
+
def app_path(path)
|
90
|
+
File.expand_path(path, Dir.pwd)
|
91
|
+
end
|
92
|
+
|
93
|
+
def browserstack?
|
94
|
+
ENV['TEST_ENV'] == 'browserstack'
|
95
|
+
end
|
96
|
+
|
97
|
+
def browserstack_caps
|
98
|
+
@browserstack_caps ||= YAML.load_file('config/capabilities.yml')['browserstack']
|
99
|
+
end
|
100
|
+
|
101
|
+
def configure_driver
|
102
|
+
if browserstack?
|
103
|
+
Appium::Driver.new({ caps: browserstack_caps,
|
104
|
+
'appium_lib': { server_url: parsed_browserstack_url}}, true)
|
105
|
+
else
|
106
|
+
Appium::Driver.new({ caps: parsed_caps })
|
107
|
+
end
|
108
|
+
end
|
109
|
+
|
110
|
+
def parsed_browserstack_url
|
111
|
+
username = ENV['BROWSERSTACK_USER']
|
112
|
+
access_key = ENV['BROWSERSTACK_KEY']
|
113
|
+
"https://#{username}:#{access_key}@hub-cloud.browserstack.com/wd/hub"
|
114
|
+
end
|
69
115
|
<% end -%>
|
data/lib/version
CHANGED
@@ -1,2 +1 @@
|
|
1
|
-
1.0.
|
2
|
-
|
1
|
+
1.0.8
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby_raider
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Agustin Pequeno
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-09-
|
11
|
+
date: 2024-09-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -268,7 +268,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
268
268
|
- !ruby/object:Gem::Version
|
269
269
|
version: '0'
|
270
270
|
requirements: []
|
271
|
-
rubygems_version: 3.
|
271
|
+
rubygems_version: 3.3.26
|
272
272
|
signing_key:
|
273
273
|
specification_version: 4
|
274
274
|
summary: A gem to make setup and start of UI automation projects easier
|