ruby-mobile-appium-template 1.0.9 → 1.1.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 +4 -4
- data/lib/ruby_appium.rb +57 -56
- 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: 0152d4b0a4ed5cb1bd17dbcefa23913a81e2b9153fc29b245e9fb563fd42bf89
|
4
|
+
data.tar.gz: 2a0c32c2745a16f64a27cb846996a3691ad4dcd72ea7a171b18ca9c0631fb7c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '095af323928046a9fce3b3a0e9f305a672e18a830eb58f7a240f8e9920cd9fca7ae7f51ca0cd3f8dc37601ce2047e29328dc6719877e925423dfca2719ea0d28'
|
7
|
+
data.tar.gz: f7584ccbccaaf73c7f4ed29d3bc4ee42d10a550dc6ff6bcd6553dcd064ac50b139061984cda1fc78bf68f2ac4479900c25950ba238c584246b38c07f685843df
|
data/lib/ruby_appium.rb
CHANGED
@@ -1,22 +1,23 @@
|
|
1
|
-
require
|
2
|
-
require
|
3
|
-
require
|
1
|
+
require "thor"
|
2
|
+
require "thor/group"
|
3
|
+
require "fileutils"
|
4
4
|
|
5
5
|
class RubyAppium < Thor::Group
|
6
6
|
include Thor::Actions
|
7
7
|
|
8
|
-
VERSION = "1.0
|
8
|
+
VERSION = "1.1.0"
|
9
9
|
|
10
10
|
argument :dir_name
|
11
11
|
|
12
12
|
def self.source_root
|
13
|
-
File.join(File.dirname(__FILE__),
|
13
|
+
File.join(File.dirname(__FILE__), "..", "templates")
|
14
14
|
|
15
15
|
end
|
16
16
|
|
17
17
|
def create_new_cucumber_directory
|
18
|
-
self.destination_root = File.expand_path(dir_name
|
18
|
+
self.destination_root = File.expand_path(dir_name)
|
19
19
|
puts destination_root
|
20
|
+
puts self.destination_root
|
20
21
|
make_empty_directory
|
21
22
|
FileUtils.cd(destination_root)
|
22
23
|
gemfile_rakefile_cukeyml
|
@@ -27,89 +28,89 @@ class RubyAppium < Thor::Group
|
|
27
28
|
protected
|
28
29
|
|
29
30
|
def make_empty_directory
|
30
|
-
empty_directory
|
31
|
+
empty_directory "."
|
31
32
|
end
|
32
33
|
|
33
34
|
def create_folders
|
34
|
-
empty_directory
|
35
|
-
empty_directory
|
36
|
-
empty_directory
|
35
|
+
empty_directory "app"
|
36
|
+
empty_directory "config"
|
37
|
+
empty_directory "features"
|
37
38
|
|
38
|
-
inside
|
39
|
-
empty_directory
|
40
|
-
empty_directory
|
39
|
+
inside "app" do
|
40
|
+
empty_directory "ios"
|
41
|
+
empty_directory "android"
|
41
42
|
end
|
42
43
|
|
43
|
-
inside
|
44
|
-
empty_directory
|
45
|
-
empty_directory
|
44
|
+
inside "config" do
|
45
|
+
empty_directory "ios"
|
46
|
+
empty_directory "android"
|
46
47
|
end
|
47
48
|
|
48
|
-
inside
|
49
|
-
empty_directory
|
50
|
-
empty_directory
|
49
|
+
inside "features" do
|
50
|
+
empty_directory "login"
|
51
|
+
empty_directory "support"
|
51
52
|
end
|
52
53
|
|
53
|
-
inside
|
54
|
-
empty_directory
|
55
|
-
empty_directory
|
56
|
-
empty_directory
|
57
|
-
empty_directory
|
58
|
-
empty_directory
|
54
|
+
inside "features/login" do
|
55
|
+
empty_directory "features"
|
56
|
+
empty_directory "data"
|
57
|
+
empty_directory "elements"
|
58
|
+
empty_directory "pageobjects"
|
59
|
+
empty_directory "steps"
|
59
60
|
end
|
60
61
|
end
|
61
62
|
|
62
63
|
def create_files
|
63
|
-
inside
|
64
|
-
template
|
65
|
-
template
|
64
|
+
inside "#{destination_root}/config/ios" do
|
65
|
+
template "#{destination_root}/config/ios/appium.txt", "appium.txt"
|
66
|
+
template "#{destination_root}/config/ios/appium_farm.txt", "appium_farm.txt"
|
66
67
|
end
|
67
68
|
|
68
|
-
inside
|
69
|
-
template
|
70
|
-
template
|
69
|
+
inside "#{destination_root}/config/android" do
|
70
|
+
template "#{destination_root}/config/android/appium.txt", "appium.txt"
|
71
|
+
template "#{destination_root}/config/android/appium_farm.txt", "appium_farm.txt"
|
71
72
|
end
|
72
73
|
|
73
|
-
inside
|
74
|
-
template
|
75
|
-
template
|
76
|
-
template
|
77
|
-
template
|
74
|
+
inside "#{destination_root}/features/support" do
|
75
|
+
template "#{destination_root}/features/support/env.rb", "env.rb"
|
76
|
+
template "#{destination_root}/features/support/hooks.rb", "hooks.rb"
|
77
|
+
template "#{destination_root}/eatures/support/utils.rb", "utils.rb"
|
78
|
+
template "#{destination_root}/features/support/appium_custom.rb", "appium_custom.rb"
|
78
79
|
end
|
79
80
|
|
80
|
-
inside
|
81
|
-
template
|
81
|
+
inside "#{destination_root}/features/login/features" do
|
82
|
+
template "#{destination_root}/eatures/login/features/login.feature", "login.feature"
|
82
83
|
end
|
83
84
|
|
84
|
-
inside
|
85
|
-
template
|
85
|
+
inside "#{destination_root}/features/login/data" do
|
86
|
+
template "#{destination_root}/features/login/data/login.yaml","data/login.yaml"
|
86
87
|
end
|
87
88
|
|
88
|
-
inside
|
89
|
-
template
|
90
|
-
template
|
91
|
-
template
|
92
|
-
template
|
89
|
+
inside "#{destination_root}/features/login/elements" do
|
90
|
+
template "#{destination_root}/features/login/elements/screen_mappings_home.yaml","screen_mappings_home.yaml"
|
91
|
+
template "#{destination_root}/features/login/elements/screen_mappings_login.yaml","screen_mappings_login.yaml"
|
92
|
+
template "#{destination_root}/features/login/elements/screen_mappings_organizadorhome.yaml","screen_mappings_organizadorhome.yaml"
|
93
|
+
template "#{destination_root}/features/login/elements/screen_mappings_token.yaml","screen_mappings_token.yaml"
|
93
94
|
end
|
94
95
|
|
95
|
-
inside
|
96
|
-
template
|
97
|
-
template
|
98
|
-
template
|
99
|
-
template
|
100
|
-
template
|
96
|
+
inside "#{destination_root}/features/login/pageobjects" do
|
97
|
+
template "#{destination_root}/features/login/pageobjects/home.rb","home.rb"
|
98
|
+
template "#{destination_root}/features/login/pageobjects/login.rb","login.rb"
|
99
|
+
template "#{destination_root}/features/login/pageobjects/loginPages.rb","loginPages.rb"
|
100
|
+
template "#{destination_root}/features/login/pageobjects/organizadorHome.rb","organizadorHome.rb"
|
101
|
+
template "#{destination_root}/features/login/pageobjects/token.rb","token.rb"
|
101
102
|
end
|
102
103
|
|
103
|
-
inside
|
104
|
-
template
|
104
|
+
inside "#{destination_root}/features/login/steps" do
|
105
|
+
template "#{destination_root}/features/login/steps/login_steps.rb","login_steps.rb"
|
105
106
|
end
|
106
107
|
end
|
107
108
|
|
108
109
|
def gemfile_rakefile_cukeyml
|
109
110
|
inside destination_root do
|
110
|
-
template
|
111
|
-
template
|
112
|
-
template
|
111
|
+
template "Gemfile"
|
112
|
+
template "Rakefile"
|
113
|
+
template "cucumber.yml"
|
113
114
|
end
|
114
115
|
end
|
115
116
|
|