Ifd_Mobile 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/Ifd_Mobile/{lib_web.rb → lib_steps.rb} +36 -14
- data/lib/Ifd_Mobile/methods/core.rb +16 -4
- data/lib/Ifd_Mobile/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5764f9e3947fec819218c26edaf9e5d0f3a7fec8
|
4
|
+
data.tar.gz: 8cadb98135a46cb6f829b130fca037e5f9672e8d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 65a4fdfd2c3ad5c5a16c5150e47b30569ca3cacefe32911347a4ac0a2574db13b804066116a3e77d114e882f6d42e861782e5fb943c02a13b1e6c8cddfecd44a
|
7
|
+
data.tar.gz: 89e74c9a7bc4734254ed4f7e871dc6f156127766f4dfa07fb7ef86e3fdeabcb45adf24c8753c20b1963bfed9d6432947c8cb4eecd18bbd4b233069b163fe1ef0
|
@@ -37,16 +37,16 @@ Given /^I get attribute of element "(.*)"$/ do |element|
|
|
37
37
|
puts actual_value
|
38
38
|
end
|
39
39
|
|
40
|
-
And /^I rotate device to (landscape|portrait)$/ do |type|
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
end
|
40
|
+
# And /^I rotate device to (landscape|portrait)$/ do |type|
|
41
|
+
# case type.to_sym
|
42
|
+
# when :landscape
|
43
|
+
# $driver.rotate :landscape
|
44
|
+
# when :portrait
|
45
|
+
# $driver.rotate :portrait
|
46
|
+
# else
|
47
|
+
# raise "ERROR: *** unknown rotate type"
|
48
|
+
# end
|
49
|
+
# end
|
50
50
|
|
51
51
|
And /^I accept alert$/ do
|
52
52
|
selenium.alert_accept
|
@@ -60,10 +60,6 @@ And /^I hide the keyboard$/ do
|
|
60
60
|
selenium.hide_keyboard
|
61
61
|
end
|
62
62
|
|
63
|
-
And /^I delete an character$/ do
|
64
|
-
system('adb shell input keyevent 67')
|
65
|
-
end
|
66
|
-
|
67
63
|
Then(/^I tap on back button of device$/) do
|
68
64
|
navigate('back')
|
69
65
|
end
|
@@ -116,3 +112,29 @@ end
|
|
116
112
|
Then(/^I reset app$/) do
|
117
113
|
reset_app
|
118
114
|
end
|
115
|
+
|
116
|
+
And /^I delete an character on Android$/ do
|
117
|
+
delete_an_character_android
|
118
|
+
end
|
119
|
+
|
120
|
+
And /^I take a photo on Android$/ do
|
121
|
+
take_photo_android
|
122
|
+
end
|
123
|
+
|
124
|
+
And /^I go home screen Android$/ do
|
125
|
+
move_home
|
126
|
+
end
|
127
|
+
|
128
|
+
And /^I set app to run background within (\d+)$/ do |seconds|
|
129
|
+
selenium.background_app seconds
|
130
|
+
end
|
131
|
+
|
132
|
+
And /^I press button (\d+)$/ do |button_index|
|
133
|
+
# Find a button by index
|
134
|
+
button(button_index.to_i).click
|
135
|
+
end
|
136
|
+
|
137
|
+
Given /^I set text "(.*)" on filed index (\d+)$/ do |value, field|
|
138
|
+
# Get a textfield by index
|
139
|
+
textfield(field.to_i).type value
|
140
|
+
end
|
@@ -232,13 +232,25 @@ def long_press_on_coordinates_with_duration(x, y, duration)
|
|
232
232
|
end
|
233
233
|
|
234
234
|
def close_app
|
235
|
-
|
235
|
+
selenium.close_app
|
236
236
|
end
|
237
237
|
|
238
238
|
def launch_app
|
239
|
-
|
239
|
+
selenium.launch
|
240
240
|
end
|
241
241
|
|
242
242
|
def reset_app
|
243
|
-
|
244
|
-
end
|
243
|
+
selenium.reset
|
244
|
+
end
|
245
|
+
|
246
|
+
def delete_an_character_android
|
247
|
+
system('adb shell input keyevent 67')
|
248
|
+
end
|
249
|
+
|
250
|
+
def take_photo_android
|
251
|
+
system('adb shell input keyevent 27')
|
252
|
+
end
|
253
|
+
|
254
|
+
def move_home
|
255
|
+
selenium.key_event 3
|
256
|
+
end
|
data/lib/Ifd_Mobile/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: Ifd_Mobile
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Anh Pham
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cucumber
|
@@ -78,7 +78,7 @@ executables:
|
|
78
78
|
extensions: []
|
79
79
|
extra_rdoc_files: []
|
80
80
|
files:
|
81
|
-
- lib/Ifd_Mobile/
|
81
|
+
- lib/Ifd_Mobile/lib_steps.rb
|
82
82
|
- lib/Ifd_Mobile/methods/core.rb
|
83
83
|
- lib/Ifd_Mobile/methods/IFD_Assertion.rb
|
84
84
|
- lib/Ifd_Mobile/methods/lib_var.rb
|