calabash-cucumber 0.9.116 → 0.9.117
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile.lock +1 -1
- data/bin/calabash-ios +1 -0
- data/features/step_definitions/calabash_steps.rb +1 -1
- data/lib/calabash-cucumber/ibase.rb +37 -0
- data/lib/calabash-cucumber/keyboard_helpers.rb +5 -0
- data/lib/calabash-cucumber/operations.rb +9 -0
- data/lib/calabash-cucumber/version.rb +2 -2
- data/lib/calabash-cucumber/wait_helpers.rb +6 -0
- metadata +124 -130
data/Gemfile.lock
CHANGED
data/bin/calabash-ios
CHANGED
@@ -230,7 +230,7 @@ Then /^I pinch to zoom (in|out) on "([^\"]*)"$/ do |in_out, name|
|
|
230
230
|
sleep(STEP_PAUSE)
|
231
231
|
end
|
232
232
|
|
233
|
-
# Note "up/left/right" seems to be missing on the web
|
233
|
+
# Note "up/left/right" seems to be missing on the web base
|
234
234
|
Then /^I scroll (left|right|up|down)$/ do |dir|
|
235
235
|
scroll("scrollView index:0", dir)
|
236
236
|
sleep(STEP_PAUSE)
|
@@ -0,0 +1,37 @@
|
|
1
|
+
require 'calabash-cucumber/core'
|
2
|
+
require 'calabash-cucumber/operations'
|
3
|
+
|
4
|
+
class Calabash::IBase
|
5
|
+
include Calabash::Cucumber::Operations
|
6
|
+
|
7
|
+
def initialize(world)
|
8
|
+
@world = world
|
9
|
+
end
|
10
|
+
|
11
|
+
def embed(*args)
|
12
|
+
@world.send(:embed,*args)
|
13
|
+
end
|
14
|
+
|
15
|
+
def puts(*args)
|
16
|
+
@world.send(:puts, *args)
|
17
|
+
end
|
18
|
+
|
19
|
+
def trait
|
20
|
+
"navigationItemView marked:'#{self.title}'"
|
21
|
+
end
|
22
|
+
|
23
|
+
def base(clz,*args)
|
24
|
+
clz.new(@world,*args)
|
25
|
+
end
|
26
|
+
|
27
|
+
def await(opts={})
|
28
|
+
wait_for_elements_exist([trait], opts)
|
29
|
+
self
|
30
|
+
end
|
31
|
+
|
32
|
+
def await_screenshot(wait_opts={},screenshot_opts={})
|
33
|
+
await(wait_opts)
|
34
|
+
screenshot_embed(screenshot_opts)
|
35
|
+
end
|
36
|
+
|
37
|
+
end
|
@@ -81,6 +81,11 @@ module Calabash
|
|
81
81
|
end
|
82
82
|
end
|
83
83
|
|
84
|
+
def await_keyboard
|
85
|
+
wait_for_elements_exist(["view:'UIKBKeyplaneView'"])
|
86
|
+
sleep(0.3)
|
87
|
+
end
|
88
|
+
|
84
89
|
def keyboard_enter_text(text)
|
85
90
|
fail("No visible keyboard") if element_does_not_exist("view:'UIKBKeyplaneView'")
|
86
91
|
|
@@ -27,6 +27,15 @@ module Calabash
|
|
27
27
|
include Calabash::Cucumber::Location
|
28
28
|
|
29
29
|
|
30
|
+
|
31
|
+
def page(clz,*args)
|
32
|
+
clz.new(self,*args)
|
33
|
+
end
|
34
|
+
|
35
|
+
def await_page(clz,*args)
|
36
|
+
clz.new(self,*args).await
|
37
|
+
end
|
38
|
+
|
30
39
|
def home_direction
|
31
40
|
@current_rotation = @current_rotation || :down
|
32
41
|
end
|
@@ -49,6 +49,11 @@ module Calabash
|
|
49
49
|
|
50
50
|
def wait_poll(opts, &block)
|
51
51
|
test = opts[:until]
|
52
|
+
if test.nil?
|
53
|
+
cond = opts[:until_exists]
|
54
|
+
raise "Must provide :until or :until_exists" unless cond
|
55
|
+
test = lambda { element_exists(cond) }
|
56
|
+
end
|
52
57
|
wait_for(opts) do
|
53
58
|
if test.call()
|
54
59
|
true
|
@@ -109,6 +114,7 @@ module Calabash
|
|
109
114
|
end
|
110
115
|
|
111
116
|
def wait_for_none_animating(options = {})
|
117
|
+
#sleep(0.3)
|
112
118
|
options[:condition] = CALABASH_CONDITIONS[:none_animating]
|
113
119
|
wait_for_condition(options)
|
114
120
|
end
|
metadata
CHANGED
@@ -1,151 +1,153 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: calabash-cucumber
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.9.117
|
5
5
|
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 9
|
9
|
-
- 116
|
10
|
-
version: 0.9.116
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- Karl Krukow
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2012-11-01 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
21
15
|
name: cucumber
|
22
|
-
|
23
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
24
17
|
none: false
|
25
|
-
requirements:
|
26
|
-
- -
|
27
|
-
- !ruby/object:Gem::Version
|
28
|
-
|
29
|
-
segments:
|
30
|
-
- 0
|
31
|
-
version: "0"
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '0'
|
32
22
|
type: :runtime
|
33
|
-
version_requirements: *id001
|
34
|
-
- !ruby/object:Gem::Dependency
|
35
|
-
name: json
|
36
23
|
prerelease: false
|
37
|
-
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ! '>='
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '0'
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: json
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
38
33
|
none: false
|
39
|
-
requirements:
|
40
|
-
- -
|
41
|
-
- !ruby/object:Gem::Version
|
42
|
-
|
43
|
-
segments:
|
44
|
-
- 0
|
45
|
-
version: "0"
|
34
|
+
requirements:
|
35
|
+
- - ! '>='
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '0'
|
46
38
|
type: :runtime
|
47
|
-
version_requirements: *id002
|
48
|
-
- !ruby/object:Gem::Dependency
|
49
|
-
name: CFPropertyList
|
50
39
|
prerelease: false
|
51
|
-
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ! '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '0'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: CFPropertyList
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
52
49
|
none: false
|
53
|
-
requirements:
|
54
|
-
- -
|
55
|
-
- !ruby/object:Gem::Version
|
56
|
-
|
57
|
-
segments:
|
58
|
-
- 0
|
59
|
-
version: "0"
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
60
54
|
type: :runtime
|
61
|
-
version_requirements: *id003
|
62
|
-
- !ruby/object:Gem::Dependency
|
63
|
-
name: sim_launcher
|
64
55
|
prerelease: false
|
65
|
-
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
66
57
|
none: false
|
67
|
-
requirements:
|
68
|
-
- -
|
69
|
-
- !ruby/object:Gem::Version
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: sim_launcher
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
65
|
+
none: false
|
66
|
+
requirements:
|
67
|
+
- - '='
|
68
|
+
- !ruby/object:Gem::Version
|
75
69
|
version: 0.4.6
|
76
70
|
type: :runtime
|
77
|
-
version_requirements: *id004
|
78
|
-
- !ruby/object:Gem::Dependency
|
79
|
-
name: slowhandcuke
|
80
71
|
prerelease: false
|
81
|
-
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
82
73
|
none: false
|
83
|
-
requirements:
|
84
|
-
- -
|
85
|
-
- !ruby/object:Gem::Version
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
74
|
+
requirements:
|
75
|
+
- - '='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: 0.4.6
|
78
|
+
- !ruby/object:Gem::Dependency
|
79
|
+
name: slowhandcuke
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
81
|
+
none: false
|
82
|
+
requirements:
|
83
|
+
- - ! '>='
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: '0'
|
90
86
|
type: :runtime
|
91
|
-
version_requirements: *id005
|
92
|
-
- !ruby/object:Gem::Dependency
|
93
|
-
name: location-one
|
94
87
|
prerelease: false
|
95
|
-
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
96
89
|
none: false
|
97
|
-
requirements:
|
90
|
+
requirements:
|
91
|
+
- - ! '>='
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '0'
|
94
|
+
- !ruby/object:Gem::Dependency
|
95
|
+
name: location-one
|
96
|
+
requirement: !ruby/object:Gem::Requirement
|
97
|
+
none: false
|
98
|
+
requirements:
|
98
99
|
- - ~>
|
99
|
-
- !ruby/object:Gem::Version
|
100
|
-
hash: 15
|
101
|
-
segments:
|
102
|
-
- 0
|
103
|
-
- 0
|
104
|
-
- 8
|
100
|
+
- !ruby/object:Gem::Version
|
105
101
|
version: 0.0.8
|
106
102
|
type: :runtime
|
107
|
-
version_requirements: *id006
|
108
|
-
- !ruby/object:Gem::Dependency
|
109
|
-
name: httpclient
|
110
103
|
prerelease: false
|
111
|
-
|
104
|
+
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ~>
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: 0.0.8
|
110
|
+
- !ruby/object:Gem::Dependency
|
111
|
+
name: httpclient
|
112
|
+
requirement: !ruby/object:Gem::Requirement
|
112
113
|
none: false
|
113
|
-
requirements:
|
114
|
-
- -
|
115
|
-
- !ruby/object:Gem::Version
|
116
|
-
hash: 9
|
117
|
-
segments:
|
118
|
-
- 2
|
119
|
-
- 2
|
120
|
-
- 7
|
114
|
+
requirements:
|
115
|
+
- - '='
|
116
|
+
- !ruby/object:Gem::Version
|
121
117
|
version: 2.2.7
|
122
118
|
type: :runtime
|
123
|
-
version_requirements: *id007
|
124
|
-
- !ruby/object:Gem::Dependency
|
125
|
-
name: bundler
|
126
119
|
prerelease: false
|
127
|
-
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
none: false
|
122
|
+
requirements:
|
123
|
+
- - '='
|
124
|
+
- !ruby/object:Gem::Version
|
125
|
+
version: 2.2.7
|
126
|
+
- !ruby/object:Gem::Dependency
|
127
|
+
name: bundler
|
128
|
+
requirement: !ruby/object:Gem::Requirement
|
128
129
|
none: false
|
129
|
-
requirements:
|
130
|
+
requirements:
|
130
131
|
- - ~>
|
131
|
-
- !ruby/object:Gem::Version
|
132
|
-
|
133
|
-
segments:
|
134
|
-
- 1
|
135
|
-
- 1
|
136
|
-
version: "1.1"
|
132
|
+
- !ruby/object:Gem::Version
|
133
|
+
version: '1.1'
|
137
134
|
type: :runtime
|
138
|
-
|
139
|
-
|
140
|
-
|
135
|
+
prerelease: false
|
136
|
+
version_requirements: !ruby/object:Gem::Requirement
|
137
|
+
none: false
|
138
|
+
requirements:
|
139
|
+
- - ~>
|
140
|
+
- !ruby/object:Gem::Version
|
141
|
+
version: '1.1'
|
142
|
+
description: calabash-cucumber drives tests for native iOS apps. You must link your
|
143
|
+
app with calabash-ios-server framework to execute tests.
|
144
|
+
email:
|
141
145
|
- karl@lesspainful.com
|
142
|
-
executables:
|
146
|
+
executables:
|
143
147
|
- calabash-ios
|
144
148
|
extensions: []
|
145
|
-
|
146
149
|
extra_rdoc_files: []
|
147
|
-
|
148
|
-
files:
|
150
|
+
files:
|
149
151
|
- .gitignore
|
150
152
|
- CHANGES.txt
|
151
153
|
- Gemfile
|
@@ -177,6 +179,7 @@ files:
|
|
177
179
|
- lib/calabash-cucumber/calabash_steps.rb
|
178
180
|
- lib/calabash-cucumber/core.rb
|
179
181
|
- lib/calabash-cucumber/cucumber.rb
|
182
|
+
- lib/calabash-cucumber/ibase.rb
|
180
183
|
- lib/calabash-cucumber/keyboard_helpers.rb
|
181
184
|
- lib/calabash-cucumber/launch/simulator_helper.rb
|
182
185
|
- lib/calabash-cucumber/location.rb
|
@@ -264,36 +267,27 @@ files:
|
|
264
267
|
- scripts/reset_simulator.scpt
|
265
268
|
homepage: http://calaba.sh
|
266
269
|
licenses: []
|
267
|
-
|
268
270
|
post_install_message:
|
269
271
|
rdoc_options: []
|
270
|
-
|
271
|
-
require_paths:
|
272
|
+
require_paths:
|
272
273
|
- lib
|
273
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
274
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
274
275
|
none: false
|
275
|
-
requirements:
|
276
|
-
- -
|
277
|
-
- !ruby/object:Gem::Version
|
278
|
-
|
279
|
-
|
280
|
-
- 0
|
281
|
-
version: "0"
|
282
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
276
|
+
requirements:
|
277
|
+
- - ! '>='
|
278
|
+
- !ruby/object:Gem::Version
|
279
|
+
version: '0'
|
280
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
283
281
|
none: false
|
284
|
-
requirements:
|
285
|
-
- -
|
286
|
-
- !ruby/object:Gem::Version
|
287
|
-
|
288
|
-
segments:
|
289
|
-
- 0
|
290
|
-
version: "0"
|
282
|
+
requirements:
|
283
|
+
- - ! '>='
|
284
|
+
- !ruby/object:Gem::Version
|
285
|
+
version: '0'
|
291
286
|
requirements: []
|
292
|
-
|
293
287
|
rubyforge_project:
|
294
|
-
rubygems_version: 1.8.
|
288
|
+
rubygems_version: 1.8.23
|
295
289
|
signing_key:
|
296
290
|
specification_version: 3
|
297
291
|
summary: Client for calabash-ios-server for automated functional testing on iOS
|
298
|
-
test_files:
|
292
|
+
test_files:
|
299
293
|
- features/step_definitions/calabash_steps.rb
|