ruby-mobile-appium-template 1.1.4 → 1.1.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 417f8d78b2f4a5652ff4c694e78c726de658bb455bc02155e4f2a5fd5d9c5dd6
4
- data.tar.gz: 4853ac848ed1abec25e40d3083bb0b202da164f2bd5cbe398adfd315a991c3d5
3
+ metadata.gz: 40170d8e72211968c64972397b75e8ad2c6f3bb66ddc3b80e9053383b40c989c
4
+ data.tar.gz: 6a01c176d7f0965a72e569cb78d10996047e5b6232bc4ff976d5eae2bc80639e
5
5
  SHA512:
6
- metadata.gz: 7c0c68e8f93e15865769fb59a2463df8d3eb27703151a19e0d27c4f4bdbbfcf1416458bc22a027f935dd1a22cf279194c6ab3b12353daf25912bf76b1369564f
7
- data.tar.gz: 2fb2aeb5ab41a404305a698cc79ac6d2af48ba5e964e6f7b2d306fc468fa126202e713673eafe10b41c1db3b5f242dd79da728bde54e0d32b1bfae74cd63ae93
6
+ metadata.gz: 70555eabd305f9193e16046f6baed0914541e3fe6375ede21ce8f4f0a0f878e7591eefd78245b4e153f46008616c4388fabb991f45a029de8919127cdf79f8fa
7
+ data.tar.gz: 711fec9bafc5e263ade26083886ef194a0d0d215bf3949ffad88c35e52fcdd1fcdd75786651da1959ba73db387475dbccc4040ea073aa976f944189af3436038
@@ -1,4 +1,4 @@
1
- #!/usr/bin/env ruby
2
-
3
- require 'ruby_appium'
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'ruby_appium'
4
4
  RubyAppium.start
data/lib/ruby_appium.rb CHANGED
@@ -1,116 +1,115 @@
1
- require "thor"
2
- require "thor/group"
3
- require "fileutils"
4
-
5
- class RubyAppium < Thor::Group
6
- include Thor::Actions
7
-
8
- VERSION = "1.1.4"
9
-
10
- argument :dir_name
11
-
12
- def self.source_root
13
- File.join(File.dirname(__FILE__), "..", "templates")
14
-
15
- end
16
-
17
- def create_new_cucumber_directory
18
- self.destination_root = File.expand_path(dir_name)
19
- make_empty_directory
20
- FileUtils.cd(destination_root)
21
- gemfile_rakefile_cukeyml
22
- create_folders
23
- create_files
24
- end
25
-
26
- protected
27
-
28
- def make_empty_directory
29
- empty_directory "."
30
- end
31
-
32
- def create_folders
33
- empty_directory "app"
34
- empty_directory "config"
35
- empty_directory "features"
36
-
37
- inside "app" do
38
- empty_directory "ios"
39
- empty_directory "android"
40
- end
41
-
42
- inside "config" do
43
- empty_directory "ios"
44
- empty_directory "android"
45
- end
46
-
47
- inside "features" do
48
- empty_directory "login"
49
- empty_directory "support"
50
- end
51
-
52
- inside "features/login" do
53
- empty_directory "features"
54
- empty_directory "data"
55
- empty_directory "elements"
56
- empty_directory "pageobjects"
57
- empty_directory "steps"
58
- end
59
- end
60
-
61
- def create_files
62
- inside "config/ios" do
63
- template "config/ios/appium.txt", "appium.txt"
64
- template "config/ios/appium_farm.txt", "appium_farm.txt"
65
- end
66
-
67
- inside "config/android" do
68
- template "config/android/appium.txt", "appium.txt"
69
- template "config/android/appium_farm.txt", "appium_farm.txt"
70
- end
71
-
72
- inside "features/support" do
73
- template "features/support/env.rb", "env.rb"
74
- template "features/support/hooks.rb", "hooks.rb"
75
- template "eatures/support/utils.rb", "utils.rb"
76
- template "features/support/appium_custom.rb", "appium_custom.rb"
77
- end
78
-
79
- inside "features/login/features" do
80
- template "eatures/login/features/login.feature", "login.feature"
81
- end
82
-
83
- inside "features/login/data" do
84
- template "features/login/data/login.yaml","data/login.yaml"
85
- end
86
-
87
- inside "features/login/elements" do
88
- template "features/login/elements/screen_mappings_home.yaml","screen_mappings_home.yaml"
89
- template "features/login/elements/screen_mappings_login.yaml","screen_mappings_login.yaml"
90
- template "features/login/elements/screen_mappings_organizadorhome.yaml","screen_mappings_organizadorhome.yaml"
91
- template "features/login/elements/screen_mappings_token.yaml","screen_mappings_token.yaml"
92
- end
93
-
94
- inside "features/login/pageobjects" do
95
- template "features/login/pageobjects/home.rb","home.rb"
96
- template "features/login/pageobjects/login.rb","login.rb"
97
- template "features/login/pageobjects/loginPages.rb","loginPages.rb"
98
- template "features/login/pageobjects/organizadorHome.rb","organizadorHome.rb"
99
- template "features/login/pageobjects/token.rb","token.rb"
100
- end
101
-
102
- inside "features/login/steps" do
103
- template "features/login/steps/login_steps.rb","login_steps.rb"
104
- end
105
- end
106
-
107
- def gemfile_rakefile_cukeyml
108
- inside destination_root do
109
- template "Gemfile"
110
- template "Rakefile"
111
- template "cucumber.yml"
112
- template "appium.txt", "config/ios/appium.txt"
113
- end
114
- end
115
-
116
- end
1
+ require "thor"
2
+ require "thor/group"
3
+ require "fileutils"
4
+
5
+ class RubyAppium < Thor::Group
6
+ include Thor::Actions
7
+
8
+ VERSION = "1.1.7"
9
+
10
+ argument :dir_name
11
+
12
+ def self.source_root
13
+ File.join(File.dirname(__FILE__), "..", "templates")
14
+
15
+ end
16
+
17
+ def create_new_cucumber_directory
18
+ self.destination_root = File.expand_path(dir_name)
19
+ make_empty_directory
20
+ FileUtils.cd(destination_root)
21
+ gemfile_rakefile_cukeyml
22
+ create_folders
23
+ create_files
24
+ end
25
+
26
+ protected
27
+
28
+ def make_empty_directory
29
+ empty_directory "."
30
+ end
31
+
32
+ def create_folders
33
+ empty_directory "app"
34
+ empty_directory "config"
35
+ empty_directory "features"
36
+
37
+ inside "app" do
38
+ empty_directory "ios"
39
+ empty_directory "android"
40
+ end
41
+
42
+ inside "config" do
43
+ empty_directory "ios"
44
+ empty_directory "android"
45
+ end
46
+
47
+ inside "features" do
48
+ empty_directory "login"
49
+ empty_directory "support"
50
+ end
51
+
52
+ inside "features/login" do
53
+ empty_directory "features"
54
+ empty_directory "data"
55
+ empty_directory "elements"
56
+ empty_directory "pageobjects"
57
+ empty_directory "steps"
58
+ end
59
+ end
60
+
61
+ def create_files
62
+ inside "config/ios" do
63
+ template "appium.txt"
64
+ template "appium_farm.txt"
65
+ end
66
+
67
+ inside "config/android" do
68
+ template "appium.txt"
69
+ template "appium_farm.txt"
70
+ end
71
+
72
+ inside "features/support" do
73
+ template "env.rb"
74
+ template "hooks.rb"
75
+ template "utils.rb"
76
+ template "appium_custom.rb"
77
+ end
78
+
79
+ inside "features/login/features" do
80
+ template "login.feature"
81
+ end
82
+
83
+ inside "features/login/data" do
84
+ template "login.yaml"
85
+ end
86
+
87
+ inside "features/login/elements" do
88
+ template "screen_mappings_home.yaml"
89
+ template "screen_mappings_login.yaml"
90
+ template "screen_mappings_organizadorhome.yaml"
91
+ template "screen_mappings_token.yaml"
92
+ end
93
+
94
+ inside "features/login/pageobjects" do
95
+ template "home.rb"
96
+ template "login.rb"
97
+ template "loginPages.rb"
98
+ template "organizadorHome.rb"
99
+ template "token.rb"
100
+ end
101
+
102
+ inside "features/login/steps" do
103
+ template "login_steps.rb"
104
+ end
105
+ end
106
+
107
+ def gemfile_rakefile_cukeyml
108
+ inside destination_root do
109
+ template "Gemfile"
110
+ template "Rakefile"
111
+ template "cucumber.yml"
112
+ end
113
+ end
114
+
115
+ end
@@ -0,0 +1,256 @@
1
+ ##############################JAZZIGNORE#################################
2
+ .jazzignore
3
+
4
+ ##############################IDE ECLIPSE################################
5
+ .metadata
6
+ tmp/
7
+ *.tmp
8
+ *.bak
9
+ *.swp
10
+ *~.nib
11
+ local.properties
12
+ .settings/
13
+ .loadpath
14
+ .recommenders
15
+
16
+ # External tool builders
17
+ .externalToolBuilders/
18
+
19
+ # Locally stored "Eclipse launch configurations"
20
+ *.launch
21
+
22
+ # PyDev specific (Python IDE for Eclipse)
23
+ *.pydevproject
24
+
25
+ # CDT-specific (C/C++ Development Tooling)
26
+ .cproject
27
+
28
+ # CDT- autotools
29
+ .autotools
30
+
31
+ # Java annotation processor (APT)
32
+ .factorypath
33
+
34
+ # PDT-specific (PHP Development Tools)
35
+ .buildpath
36
+
37
+ # sbteclipse plugin
38
+ .target
39
+
40
+ # Tern plugin
41
+ .tern-project
42
+
43
+ # TeXlipse plugin
44
+ .texlipse
45
+
46
+ # STS (Spring Tool Suite)
47
+ .springBeans
48
+
49
+ # Code Recommenders
50
+ .recommenders/
51
+
52
+ # Scala IDE specific (Scala & Java development for Eclipse)
53
+ .cache-main
54
+ .scala_dependencies
55
+ .worksheet
56
+
57
+
58
+ ##############################IDE JETBRAINS################################
59
+
60
+ # User-specific stuff:
61
+ .idea/**/workspace.xml
62
+ .idea/**/tasks.xml
63
+ .idea/dictionaries
64
+
65
+ # Sensitive or high-churn files:
66
+ .idea/**/dataSources/
67
+ .idea/**/dataSources.ids
68
+ .idea/**/dataSources.xml
69
+ .idea/**/dataSources.local.xml
70
+ .idea/**/sqlDataSources.xml
71
+ .idea/**/dynamic.xml
72
+ .idea/**/uiDesigner.xml
73
+
74
+ # Gradle:
75
+ .idea/**/gradle.xml
76
+ .idea/**/libraries
77
+
78
+ # CMake
79
+ cmake-build-debug/
80
+ cmake-build-release/
81
+
82
+ # Mongo Explorer plugin:
83
+ .idea/**/mongoSettings.xml
84
+
85
+ ## File-based project format:
86
+ *.iws
87
+
88
+ ## Plugin-specific files:
89
+
90
+ # IntelliJ
91
+ out/
92
+
93
+ # mpeltonen/sbt-idea plugin
94
+ .idea_modules/
95
+
96
+ # JIRA plugin
97
+ atlassian-ide-plugin.xml
98
+
99
+ # Cursive Clojure plugin
100
+ .idea/replstate.xml
101
+
102
+ # Crashlytics plugin (for Android Studio and IntelliJ)
103
+ com_crashlytics_export_strings.xml
104
+ crashlytics.properties
105
+ crashlytics-build.properties
106
+ fabric.properties
107
+
108
+ ##############################VISUAL STUDIO CODE################################
109
+
110
+ .vscode/*
111
+ !.vscode/settings.json
112
+ !.vscode/tasks.json
113
+ !.vscode/launch.json
114
+ !.vscode/extensions.json
115
+
116
+ ##############################SUBLIME############################################
117
+
118
+ # Cache files for Sublime Text
119
+ *.tmlanguage.cache
120
+ *.tmPreferences.cache
121
+ *.stTheme.cache
122
+
123
+ # Workspace files are user-specific
124
+ *.sublime-workspace
125
+
126
+ # Project files should be checked into the repository, unless a significant
127
+ # proportion of contributors will probably not be using Sublime Text
128
+ # *.sublime-project
129
+
130
+ # SFTP configuration file
131
+ sftp-config.json
132
+
133
+ # Package control specific files
134
+ Package Control.last-run
135
+ Package Control.ca-list
136
+ Package Control.ca-bundle
137
+ Package Control.system-ca-bundle
138
+ Package Control.cache/
139
+ Package Control.ca-certs/
140
+ Package Control.merged-ca-bundle
141
+ Package Control.user-ca-bundle
142
+ oscrypto-ca-bundle.crt
143
+ bh_unicode_properties.cache
144
+
145
+ #################################WINDOWS#########################################
146
+
147
+ # Windows thumbnail cache files
148
+ Thumbs.db
149
+ ehthumbs.db
150
+ ehthumbs_vista.db
151
+
152
+ # Dump file
153
+ *.stackdump
154
+
155
+ # Folder config file
156
+ [Dd]esktop.ini
157
+
158
+ # Recycle Bin used on file shares
159
+ $RECYCLE.BIN/
160
+
161
+ # Windows Installer files
162
+ *.cab
163
+ *.msi
164
+ *.msm
165
+ *.msp
166
+
167
+ # Windows shortcuts
168
+ *.lnk
169
+
170
+ #################################LINUX#########################################
171
+
172
+ *~
173
+
174
+ # temporary files which can be created if a process still has a handle open of a deleted file
175
+ .fuse_hidden*
176
+
177
+ # KDE directory preferences
178
+ .directory
179
+
180
+ # Linux trash folder which might appear on any partition or disk
181
+ .Trash-*
182
+
183
+ # .nfs files are created when an open file is removed but is still being accessed
184
+ .nfs*
185
+
186
+ #################################MACOS#########################################
187
+ # General
188
+ .DS_Store
189
+ .AppleDouble
190
+ .LSOverride
191
+
192
+ # Thumbnails
193
+ ._*
194
+
195
+ # Files that might appear in the root of a volume
196
+ .DocumentRevisions-V100
197
+ .fseventsd
198
+ .Spotlight-V100
199
+ .TemporaryItems
200
+ .Trashes
201
+ .VolumeIcon.icns
202
+ .com.apple.timemachine.donotpresent
203
+
204
+ # Directories potentially created on remote AFP share
205
+ .AppleDB
206
+ .AppleDesktop
207
+ Network Trash Folder
208
+ Temporary Items
209
+ .apdisk
210
+
211
+ */target/*
212
+ target
213
+ docker/*.jar
214
+
215
+ */.idea/*
216
+ *.iml
217
+
218
+ # Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
219
+ # Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
220
+
221
+ # User-specific stuff
222
+ .idea/**/usage.statistics.xml
223
+ .idea/**/dictionaries
224
+ .idea/**/shelf
225
+
226
+ # Generated files
227
+ .idea/**/contentModel.xml
228
+
229
+ # Gradle and Maven with auto-import
230
+ # When using Gradle or Maven with auto-import, you should exclude module files,
231
+ # since they will be recreated, and may cause churn. Uncomment if using
232
+ # auto-import.
233
+ # .idea/artifacts
234
+ # .idea/compiler.xml
235
+ # .idea/jarRepositories.xml
236
+ # .idea/modules.xml
237
+ # .idea/*.iml
238
+ # .idea/modules
239
+ # *.iml
240
+ # *.ipr
241
+
242
+ # CMake
243
+ cmake-build-*/
244
+
245
+ # Editor-based Rest Client
246
+ .idea/httpRequests
247
+
248
+ # Android studio 3.1+ serialized cache file
249
+ .idea
250
+
251
+ # Arquivos de execução
252
+ /allure-results
253
+ /allure-report/
254
+ /exec-logs
255
+ /app
256
+ Gemfile.lock
data/templates/Gemfile CHANGED
@@ -1,15 +1,15 @@
1
- source 'https://rubygems.org'
2
-
3
- # frozen_string_literal: true
4
-
5
- gem 'allure-cucumber'
6
- gem 'appium_console'
7
- gem 'appium_lib'
8
- gem 'cucumber'
9
- gem 'capybara'
10
- gem 'pry'
11
- gem 'rake'
12
- gem 'selenium-webdriver'
13
- gem 'rspec'
14
- gem 'eventmachine'
1
+ source 'https://rubygems.org'
2
+
3
+ # frozen_string_literal: true
4
+
5
+ gem 'allure-cucumber'
6
+ gem 'appium_console'
7
+ gem 'appium_lib'
8
+ gem 'cucumber'
9
+ gem 'capybara'
10
+ gem 'pry'
11
+ gem 'rake'
12
+ gem 'selenium-webdriver'
13
+ gem 'rspec'
14
+ gem 'eventmachine'
15
15
  gem 'rest-client'
@@ -0,0 +1,18 @@
1
+ [caps]
2
+ automationName="UiAutomator2"
3
+ platformName = "Android"
4
+
5
+ #deviceName = "emulator-5554"
6
+ app = "./app/android/app-debug.apk"
7
+ avd = "Pixel_2_API_30"
8
+
9
+ appPackage = ""
10
+ appActivity = ""
11
+
12
+ newCommandTimeout = 3600
13
+ autoGrantPermissions = true
14
+
15
+ [appium_lib]
16
+ wait = 20
17
+ debug = true
18
+ export_session = true
@@ -0,0 +1,21 @@
1
+ [caps]
2
+ platformName = "Android"
3
+ automationName ="UiAutomator2"
4
+
5
+ # Device Farm
6
+
7
+ tenantId = "999999999"
8
+ udid = "520348e2596bb38f"
9
+ server_url = ""
10
+ appPackage = ""
11
+ appActivity = ""
12
+ mcWorkspaceName = ""
13
+
14
+ autoGrantPermissions = true
15
+ newCommandTimeout = 3600
16
+
17
+ [appium_lib]
18
+ wait = 20
19
+ debug = true
20
+ export_session = true
21
+
File without changes
@@ -0,0 +1,17 @@
1
+ [caps]
2
+ automationName = "XCUITest"
3
+ platformName = "iOS"
4
+
5
+ # Device Farm
6
+ server_url = ""
7
+ tenantId = "999999999"
8
+ udid = "ca3a1864dcf5fe2f79b2ec43765096820f604254"
9
+ bundleId = ""
10
+
11
+ autoAcceptAlerts = true
12
+ autoGrantPermissions = true
13
+
14
+ [appium_lib]
15
+ wait = 20
16
+ debug = false
17
+ export_session = true
@@ -1,6 +1,6 @@
1
-
2
- android_local: PLATFORM='android' WHERE='local' --format AllureCucumber::CucumberFormatter --out allure-results/android/
3
- ios_local: PLATFORM='ios' WHERE='local' --format AllureCucumber::CucumberFormatter --out allure-results/ios/
4
- android_farm: PLATFORM='android' WHERE='farm' --format AllureCucumber::CucumberFormatter --out allure-results/android/
5
- ios_farm: PLATFORM='ios' WHERE='farm' --format AllureCucumber::CucumberFormatter --out allure-results/ios/
6
- report: --format AllureCucumber::CucumberFormatter --out allure-results/android/
1
+
2
+ android_local: PLATFORM='android' WHERE='local' --format AllureCucumber::CucumberFormatter --out allure-results/android/
3
+ ios_local: PLATFORM='ios' WHERE='local' --format AllureCucumber::CucumberFormatter --out allure-results/ios/
4
+ android_farm: PLATFORM='android' WHERE='farm' --format AllureCucumber::CucumberFormatter --out allure-results/android/
5
+ ios_farm: PLATFORM='ios' WHERE='farm' --format AllureCucumber::CucumberFormatter --out allure-results/ios/
6
+ report: --format AllureCucumber::CucumberFormatter --out allure-results/android/