calios-uia-extension 0.0.3 → 0.0.4
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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f60754db8acf0058417e71e0d68a0c73b7af1256
|
4
|
+
data.tar.gz: 1a18122986889099557ef13971cc052f622640d6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8b5b3c3caed5d8f8330272881ffe4cae22f3a36b8d34662ccea453834ccf36724a7e5da78538852ada1bff803e64ffc9715e2f5203836a9c68367ca8acf38035
|
7
|
+
data.tar.gz: 2dacdfe27072dce591b09ab27c769133dc21493cf246b3ea4d1cf8bb4114d361f3358dc000dc0fcc5cb49e7fb75d4e10ad1b9bb10b1a1eefe73990e7b4a5a531
|
@@ -1,5 +1,8 @@
|
|
1
1
|
require_relative 'uia_base'
|
2
2
|
|
3
|
+
#
|
4
|
+
# Provides handling for UIAAlert commands
|
5
|
+
#
|
3
6
|
class UIAAlert < UIABase
|
4
7
|
class << self
|
5
8
|
def visible?
|
@@ -8,7 +11,7 @@ class UIAAlert < UIABase
|
|
8
11
|
end
|
9
12
|
|
10
13
|
def not_visible?
|
11
|
-
|
14
|
+
!self.visible?
|
12
15
|
end
|
13
16
|
|
14
17
|
def confirm
|
@@ -25,7 +28,7 @@ class UIAAlert < UIABase
|
|
25
28
|
end
|
26
29
|
|
27
30
|
def tap(aButton)
|
28
|
-
|
31
|
+
Kernel.fail('invalid parameter') unless aButton.is_a?(String)
|
29
32
|
execute("uia.alert().buttons()['#{aButton}'].tap()")
|
30
33
|
end
|
31
34
|
end
|
@@ -1,5 +1,8 @@
|
|
1
1
|
require_relative 'uia_base'
|
2
2
|
|
3
|
+
#
|
4
|
+
# Provides handling for UIAPopover commands
|
5
|
+
#
|
3
6
|
class UIAPopover < UIABase
|
4
7
|
class << self
|
5
8
|
def visible?
|
@@ -8,7 +11,7 @@ class UIAPopover < UIABase
|
|
8
11
|
end
|
9
12
|
|
10
13
|
def not_visible?
|
11
|
-
|
14
|
+
!self.visible?
|
12
15
|
end
|
13
16
|
|
14
17
|
def dismiss
|
@@ -1,3 +1,6 @@
|
|
1
|
+
# rubocop:disable Metrics/LineLength
|
2
|
+
# rubocop:disable Style/AccessorMethodName
|
3
|
+
|
1
4
|
require_relative 'uia_base'
|
2
5
|
|
3
6
|
# Use these constant values when setting device orientation
|
@@ -11,6 +14,9 @@ UIA_DEVICE_ORIENTATION_FACEDOWN = 6
|
|
11
14
|
# Not defined in UIAutomation API reference. This is just a shorthand.
|
12
15
|
UIA_DEVICE_ORIENTATION_LANDSCAPE = UIA_DEVICE_ORIENTATION_LANDSCAPELEFT
|
13
16
|
|
17
|
+
#
|
18
|
+
# Provides handling for UIATarget commands
|
19
|
+
#
|
14
20
|
class UIATarget < UIABase
|
15
21
|
class << self
|
16
22
|
def set_device_orientation(aOrientation)
|
@@ -23,28 +29,32 @@ class UIATarget < UIABase
|
|
23
29
|
response(res)
|
24
30
|
end
|
25
31
|
|
26
|
-
def deactivate_app_for_duration(aDuration=5)
|
32
|
+
def deactivate_app_for_duration(aDuration = 5)
|
27
33
|
res = execute("target.deactivateAppForDuration(#{aDuration})")
|
28
34
|
response(res)
|
29
35
|
end
|
30
36
|
|
31
37
|
alias_method :send_application_to_background, :deactivate_app_for_duration
|
32
38
|
|
33
|
-
def drag_from_to_for_duration(aFromX, aFromY, aToX, aToY, aDuration=1)
|
39
|
+
def drag_from_to_for_duration(aFromX, aFromY, aToX, aToY, aDuration = 1)
|
34
40
|
res = execute("target.dragFromToForDuration({x:#{aFromX}, y:#{aFromY}}, {x:#{aToX}, y:#{aToY}}, #{aDuration})")
|
35
41
|
response(res)
|
36
42
|
end
|
37
43
|
|
38
44
|
alias_method :drag, :drag_from_to_for_duration
|
39
45
|
|
40
|
-
def pinch_close_from_to_for_duration(aFromX, aFromY,
|
46
|
+
def pinch_close_from_to_for_duration(aFromX, aFromY,
|
47
|
+
aToX, aToY,
|
48
|
+
aDuration = 1)
|
41
49
|
res = execute("target.pinchCloseFromToForDuration({x:#{aFromX}, y:#{aFromY}}, {x:#{aToX}, y:#{aToY}}, #{aDuration})")
|
42
50
|
response(res)
|
43
51
|
end
|
44
52
|
|
45
53
|
alias_method :pinch_close, :pinch_close_from_to_for_duration
|
46
54
|
|
47
|
-
def pinch_open_from_to_for_duration(aFromX, aFromY,
|
55
|
+
def pinch_open_from_to_for_duration(aFromX, aFromY,
|
56
|
+
aToX, aToY,
|
57
|
+
aDuration = 1)
|
48
58
|
res = execute("target.pinchOpenFromToForDuration({x:#{aFromX}, y:#{aFromY}}, {x:#{aToX}, y:#{aToY}}, #{aDuration})")
|
49
59
|
response(res)
|
50
60
|
end
|
metadata
CHANGED
@@ -1,19 +1,22 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: calios-uia-extension
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jani Jegoroff
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-10-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: calabash-cucumber
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0.9'
|
17
20
|
- - ">="
|
18
21
|
- !ruby/object:Gem::Version
|
19
22
|
version: 0.9.169
|
@@ -21,6 +24,9 @@ dependencies:
|
|
21
24
|
prerelease: false
|
22
25
|
version_requirements: !ruby/object:Gem::Requirement
|
23
26
|
requirements:
|
27
|
+
- - "~>"
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '0.9'
|
24
30
|
- - ">="
|
25
31
|
- !ruby/object:Gem::Version
|
26
32
|
version: 0.9.169
|