calabash-cucumber 0.18.2 → 0.19.0.pre1
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/bin/calabash-ios +0 -16
- data/bin/calabash-ios-build.rb +0 -86
- data/bin/calabash-ios-helpers.rb +0 -65
- data/bin/calabash-ios-setup.rb +5 -119
- data/bin/calabash-ios-sim.rb +0 -37
- data/bin/frank-calabash +0 -1
- data/doc/calabash-ios-help.txt +0 -8
- data/dylibs/libCalabashDyn.dylib +0 -0
- data/dylibs/libCalabashDynSim.dylib +0 -0
- data/features-skeleton/support/01_launch.rb +3 -4
- data/features/step_definitions/calabash_steps.rb +1 -7
- data/lib/calabash-cucumber.rb +1 -2
- data/lib/calabash-cucumber/actions/instruments_actions.rb +2 -3
- data/lib/calabash-cucumber/core.rb +97 -101
- data/lib/calabash-cucumber/device.rb +5 -118
- data/lib/calabash-cucumber/environment.rb +109 -5
- data/lib/calabash-cucumber/environment_helpers.rb +4 -66
- data/lib/calabash-cucumber/http/http.rb +114 -0
- data/lib/calabash-cucumber/http_helpers.rb +3 -1
- data/lib/calabash-cucumber/ipad_1x_2x.rb +5 -7
- data/lib/calabash-cucumber/keyboard_helpers.rb +0 -44
- data/lib/calabash-cucumber/launcher.rb +425 -808
- data/lib/calabash-cucumber/logging.rb +2 -74
- data/lib/calabash-cucumber/operations.rb +0 -2
- data/lib/calabash-cucumber/rotation_helpers.rb +2 -82
- data/lib/calabash-cucumber/status_bar_helpers.rb +2 -8
- data/lib/calabash-cucumber/store/preferences.rb +2 -1
- data/lib/calabash-cucumber/uia.rb +4 -9
- data/lib/calabash-cucumber/version.rb +2 -2
- data/lib/calabash-cucumber/wait_helpers.rb +0 -2
- data/staticlib/calabash.framework.zip +0 -0
- data/staticlib/libFrankCalabash.a +0 -0
- metadata +13 -143
- data/lib/calabash-cucumber/actions/playback_actions.rb +0 -109
- data/lib/calabash-cucumber/deprecated.rb +0 -34
- data/lib/calabash-cucumber/launch/simulator_helper.rb +0 -62
- data/lib/calabash-cucumber/launch/simulator_launcher.rb +0 -617
- data/lib/calabash-cucumber/playback_helpers.rb +0 -225
- data/lib/calabash-cucumber/resources/cell_swipe_ios4_ipad.base64 +0 -51
- data/lib/calabash-cucumber/resources/cell_swipe_ios4_iphone.base64 +0 -51
- data/lib/calabash-cucumber/resources/cell_swipe_ios5_ipad.base64 +0 -74
- data/lib/calabash-cucumber/resources/cell_swipe_ios5_iphone.base64 +0 -74
- data/lib/calabash-cucumber/resources/double_tap_ios5_ipad.base64 +0 -15
- data/lib/calabash-cucumber/resources/double_tap_ios5_iphone.base64 +0 -15
- data/lib/calabash-cucumber/resources/double_tap_ios6_ipad.base64 +0 -22
- data/lib/calabash-cucumber/resources/double_tap_ios6_iphone.base64 +0 -22
- data/lib/calabash-cucumber/resources/pan_ios5_ipad.base64 +0 -199
- data/lib/calabash-cucumber/resources/pan_ios5_iphone.base64 +0 -199
- data/lib/calabash-cucumber/resources/pan_ios6_ipad.base64 +0 -206
- data/lib/calabash-cucumber/resources/pan_ios6_iphone.base64 +0 -206
- data/lib/calabash-cucumber/resources/pinch_in_ios4_ipad.base64 +0 -104
- data/lib/calabash-cucumber/resources/pinch_in_ios4_iphone.base64 +0 -104
- data/lib/calabash-cucumber/resources/pinch_in_ios5_ipad.base64 +0 -144
- data/lib/calabash-cucumber/resources/pinch_in_ios5_iphone.base64 +0 -144
- data/lib/calabash-cucumber/resources/pinch_in_ios6_ipad.base64 +0 -70
- data/lib/calabash-cucumber/resources/pinch_in_ios6_iphone.base64 +0 -70
- data/lib/calabash-cucumber/resources/pinch_out_ios5_ipad.base64 +0 -207
- data/lib/calabash-cucumber/resources/pinch_out_ios5_iphone.base64 +0 -207
- data/lib/calabash-cucumber/resources/pinch_out_ios6_ipad.base64 +0 -96
- data/lib/calabash-cucumber/resources/pinch_out_ios6_iphone.base64 +0 -96
- data/lib/calabash-cucumber/resources/rotate_left_home_down_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_down_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_down_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_down_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_left_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_left_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_left_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_left_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_right_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_right_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_right_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_right_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_up_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_up_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_up_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_left_home_up_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_down_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_down_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_down_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_down_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_left_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_left_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_left_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_left_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_right_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_right_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_right_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_right_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_up_ios4_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_up_ios4_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_up_ios5_ipad.base64 +0 -2
- data/lib/calabash-cucumber/resources/rotate_right_home_up_ios5_iphone.base64 +0 -2
- data/lib/calabash-cucumber/resources/swipe_down_ios5_ipad.base64 +0 -18
- data/lib/calabash-cucumber/resources/swipe_down_ios5_iphone.base64 +0 -31
- data/lib/calabash-cucumber/resources/swipe_down_ios6_ipad.base64 +0 -25
- data/lib/calabash-cucumber/resources/swipe_down_ios6_iphone.base64 +0 -25
- data/lib/calabash-cucumber/resources/swipe_left_hard_ios4_ipad.base64 +0 -15
- data/lib/calabash-cucumber/resources/swipe_left_hard_ios4_iphone.base64 +0 -15
- data/lib/calabash-cucumber/resources/swipe_left_ios4_ipad.base64 +0 -18
- data/lib/calabash-cucumber/resources/swipe_left_ios4_iphone.base64 +0 -18
- data/lib/calabash-cucumber/resources/swipe_left_ios5_ipad.base64 +0 -17
- data/lib/calabash-cucumber/resources/swipe_left_ios5_iphone.base64 +0 -34
- data/lib/calabash-cucumber/resources/swipe_left_ios6_ipad.base64 +0 -28
- data/lib/calabash-cucumber/resources/swipe_left_ios6_iphone.base64 +0 -28
- data/lib/calabash-cucumber/resources/swipe_right_hard_ios4_ipad.base64 +0 -17
- data/lib/calabash-cucumber/resources/swipe_right_hard_ios4_iphone.base64 +0 -17
- data/lib/calabash-cucumber/resources/swipe_right_ios4_ipad.base64 +0 -13
- data/lib/calabash-cucumber/resources/swipe_right_ios4_iphone.base64 +0 -13
- data/lib/calabash-cucumber/resources/swipe_right_ios5_ipad.base64 +0 -17
- data/lib/calabash-cucumber/resources/swipe_right_ios5_iphone.base64 +0 -17
- data/lib/calabash-cucumber/resources/swipe_right_ios6_ipad.base64 +0 -25
- data/lib/calabash-cucumber/resources/swipe_right_ios6_iphone.base64 +0 -25
- data/lib/calabash-cucumber/resources/swipe_up_ios5_ipad.base64 +0 -34
- data/lib/calabash-cucumber/resources/swipe_up_ios5_iphone.base64 +0 -28
- data/lib/calabash-cucumber/resources/swipe_up_ios6_ipad.base64 +0 -25
- data/lib/calabash-cucumber/resources/swipe_up_ios6_iphone.base64 +0 -25
- data/lib/calabash-cucumber/resources/touch_done_ios4_ipad.base64 +0 -7
- data/lib/calabash-cucumber/resources/touch_done_ios4_iphone.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_done_ios5_ipad.base64 +0 -7
- data/lib/calabash-cucumber/resources/touch_done_ios5_iphone.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_hold_ios5_ipad.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_hold_ios5_iphone.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_hold_ios6_ipad.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_hold_ios6_iphone.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_ios4_ipad.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_ios4_iphone.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_ios5_ipad.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_ios5_iphone.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_ios7_ipad.base64 +0 -9
- data/lib/calabash-cucumber/resources/touch_ios7_iphone.base64 +0 -9
- data/lib/calabash-cucumber/resources/wheel_down_ios4_ipad.base64 +0 -159
- data/lib/calabash-cucumber/resources/wheel_down_ios4_iphone.base64 +0 -159
- data/lib/calabash-cucumber/resources/wheel_down_ios5_ipad.base64 +0 -156
- data/lib/calabash-cucumber/resources/wheel_down_ios5_iphone.base64 +0 -156
- data/lib/calabash-cucumber/resources/wheel_up_ios4_ipad.base64 +0 -166
- data/lib/calabash-cucumber/resources/wheel_up_ios4_iphone.base64 +0 -166
- data/lib/calabash-cucumber/resources/wheel_up_ios5_ipad.base64 +0 -156
- data/lib/calabash-cucumber/resources/wheel_up_ios5_iphone.base64 +0 -156
- data/lib/calabash-cucumber/utils/logging.rb +0 -111
- data/lib/calabash-cucumber/utils/plist_buddy.rb +0 -45
- data/lib/calabash-cucumber/utils/simulator_accessibility.rb +0 -334
- data/lib/calabash-cucumber/utils/xctools.rb +0 -101
- data/scripts/.irbrc +0 -64
- data/scripts/launch.rb +0 -48
@@ -1,101 +0,0 @@
|
|
1
|
-
require 'run_loop'
|
2
|
-
|
3
|
-
module Calabash
|
4
|
-
module Cucumber
|
5
|
-
|
6
|
-
# @deprecated 0.11.4 Replaced with RunLoop::XCTools.
|
7
|
-
# @!visibility private
|
8
|
-
# Methods for interacting with the xcode tools.
|
9
|
-
module XcodeTools
|
10
|
-
|
11
|
-
# @deprecated 0.11.4 Replaced with RunLoop::XCTools.
|
12
|
-
# Returns the path to the current developer directory.
|
13
|
-
#
|
14
|
-
# From the man pages:
|
15
|
-
#
|
16
|
-
# ```
|
17
|
-
# $ man xcode-select
|
18
|
-
# DEVELOPER_DIR
|
19
|
-
# Overrides the active developer directory. When DEVELOPER_DIR is set,
|
20
|
-
# its value will be used instead of the system-wide active developer
|
21
|
-
# directory.
|
22
|
-
#```
|
23
|
-
#
|
24
|
-
# @return [String] path to current developer directory
|
25
|
-
def xcode_developer_dir
|
26
|
-
_deprecated('0.11.4', 'Use RunLoop::XCTools', :warn)
|
27
|
-
RunLoop::XCTools.new.xcode_developer_dir
|
28
|
-
end
|
29
|
-
|
30
|
-
# @deprecated 0.10.0 not replaced
|
31
|
-
# Returns the path to the current developer `usr/bin` directory.
|
32
|
-
# @return [String] path to the current xcode binaries
|
33
|
-
def xcode_bin_dir
|
34
|
-
_deprecated('0.10.0', 'no replacement', :warn)
|
35
|
-
File.expand_path("#{xcode_developer_dir}/usr/bin")
|
36
|
-
end
|
37
|
-
|
38
|
-
# @deprecated 0.11.4 Replaced with RunLoop::XCTools.
|
39
|
-
# Method for interacting with instruments.
|
40
|
-
#
|
41
|
-
# @example Getting the path to instruments.
|
42
|
-
# instruments #=> /Applications/Xcode.app/Contents/Developer/usr/bin/instruments
|
43
|
-
#
|
44
|
-
# @example Getting a the version of instruments.
|
45
|
-
# instruments(:version) #=> 5.1.1
|
46
|
-
#
|
47
|
-
# @example Getting list of known simulators.
|
48
|
-
# instruments(:sims) #=> < list of known simulators >
|
49
|
-
#
|
50
|
-
# @param [String] cmd controls the return value. currently accepts nil,
|
51
|
-
# :sims, and :version as valid parameters
|
52
|
-
# @return [String] based on the value of +cmd+ version, a list known
|
53
|
-
# simulators, or the path to the instruments binary
|
54
|
-
# @raise [ArgumentError] if invalid +cmd+ is passed
|
55
|
-
def instruments(cmd=nil)
|
56
|
-
instruments = 'xcrun instruments'
|
57
|
-
return instruments if cmd == nil
|
58
|
-
case cmd
|
59
|
-
when :version
|
60
|
-
_deprecated('0.11.4', 'Use RunLoop::XCTools', :warn)
|
61
|
-
RunLoop::XCTools.new.instruments(cmd).to_s
|
62
|
-
when :sims
|
63
|
-
_deprecated('0.11.4', 'Use RunLoop::XCTools', :warn)
|
64
|
-
RunLoop::XCTools.new.instruments(cmd)
|
65
|
-
else
|
66
|
-
candidates = [:version, :sims]
|
67
|
-
raise(ArgumentError, "expected '#{cmd}' to be one of '#{candidates}'")
|
68
|
-
end
|
69
|
-
end
|
70
|
-
|
71
|
-
# @deprecated 0.11.4 Replaced with RunLoop::XCTools.
|
72
|
-
# Does the instruments `version` accept the -s flag?
|
73
|
-
#
|
74
|
-
# @example
|
75
|
-
# instruments_supports_hyphen_s?('4.6.3') => false
|
76
|
-
# instruments_supports_hyphen_s?('5.0.2') => true
|
77
|
-
# instruments_supports_hyphen_s?('5.1') => true
|
78
|
-
#
|
79
|
-
# @param [String] version (instruments(:version))
|
80
|
-
# a major.minor[.patch] version string
|
81
|
-
#
|
82
|
-
# @return [Boolean] true if the version is >= 5.*
|
83
|
-
def instruments_supports_hyphen_s?(version)
|
84
|
-
_deprecated('0.11.4', 'Use RunLoop::XCTools', :warn)
|
85
|
-
RunLoop::XCTools.new.instruments_supports_hyphen_s?(version)
|
86
|
-
end
|
87
|
-
|
88
|
-
# @deprecated 0.11.4 Replaced with RunLoop::XCTools.
|
89
|
-
# Returns a list of installed simulators by calling `$ instruments -s devices`.
|
90
|
-
# and parsing the output
|
91
|
-
# @return [Array<String>] an array of simulator names suitable for passing
|
92
|
-
# to instruments or xcodebuild
|
93
|
-
# @raise [RuntimeError] if the currently active instruments version does
|
94
|
-
# not support the -s flag
|
95
|
-
def installed_simulators
|
96
|
-
_deprecated('0.11.4', 'Use RunLoop::XCTools', :warn)
|
97
|
-
instruments(:sims)
|
98
|
-
end
|
99
|
-
end
|
100
|
-
end
|
101
|
-
end
|
data/scripts/.irbrc
DELETED
@@ -1,64 +0,0 @@
|
|
1
|
-
require 'rubygems'
|
2
|
-
require 'irb/completion'
|
3
|
-
require 'irb/ext/save-history'
|
4
|
-
|
5
|
-
begin
|
6
|
-
require 'awesome_print'
|
7
|
-
rescue LoadError => e
|
8
|
-
msg = ["Caught a LoadError: could not load 'awesome_print'",
|
9
|
-
"#{e}",
|
10
|
-
'',
|
11
|
-
'Use bundler (recommended) or uninstall awesome_print.',
|
12
|
-
'',
|
13
|
-
'# Use bundler (recommended)',
|
14
|
-
'$ bundle update',
|
15
|
-
'$ bundle exec calabash-ios console',
|
16
|
-
'',
|
17
|
-
'# Uninstall',
|
18
|
-
'$ gem update --system',
|
19
|
-
'$ gem uninstall -Vax --force --no-abort-on-dependent awesome_print']
|
20
|
-
puts msg
|
21
|
-
exit(1)
|
22
|
-
end
|
23
|
-
|
24
|
-
AwesomePrint.irb!
|
25
|
-
|
26
|
-
ARGV.concat [ '--readline',
|
27
|
-
'--prompt-mode',
|
28
|
-
'simple']
|
29
|
-
|
30
|
-
IRB.conf[:SAVE_HISTORY] = 50
|
31
|
-
IRB.conf[:HISTORY_FILE] = '.irb-history'
|
32
|
-
|
33
|
-
require 'calabash-cucumber/operations'
|
34
|
-
|
35
|
-
# legacy support - module was deprecated 0.9.169
|
36
|
-
# and replaced with simulator_launcher
|
37
|
-
require 'calabash-cucumber/launch/simulator_helper'
|
38
|
-
require 'calabash-cucumber/launch/simulator_launcher'
|
39
|
-
SIM=Calabash::Cucumber::SimulatorLauncher.new()
|
40
|
-
|
41
|
-
extend Calabash::Cucumber::Operations
|
42
|
-
|
43
|
-
def embed(x,y=nil,z=nil)
|
44
|
-
puts "Screenshot at #{x}"
|
45
|
-
end
|
46
|
-
|
47
|
-
require "calabash-cucumber"
|
48
|
-
|
49
|
-
def preferences
|
50
|
-
Calabash::Cucumber::Preferences.new
|
51
|
-
end
|
52
|
-
|
53
|
-
def disable_usage_tracking
|
54
|
-
preferences.usage_tracking = "none"
|
55
|
-
puts "Calabash will not collect usage information."
|
56
|
-
"none"
|
57
|
-
end
|
58
|
-
|
59
|
-
def enable_usage_tracking(level="system_info")
|
60
|
-
preferences.usage_tracking = level
|
61
|
-
puts "Calabash will collect statistics using the '#{level}' rule."
|
62
|
-
level
|
63
|
-
end
|
64
|
-
|
data/scripts/launch.rb
DELETED
@@ -1,48 +0,0 @@
|
|
1
|
-
########################################
|
2
|
-
# #
|
3
|
-
# Important Note #
|
4
|
-
# #
|
5
|
-
# When running calabash-ios tests at #
|
6
|
-
# www.xamarin.com/test-cloud #
|
7
|
-
# this file will be overwritten by #
|
8
|
-
# a file which automates #
|
9
|
-
# app launch on devices. #
|
10
|
-
# #
|
11
|
-
# Don't rely on this file being #
|
12
|
-
# present when running at #
|
13
|
-
# Xamarin Test Cloud #
|
14
|
-
# #
|
15
|
-
########################################
|
16
|
-
|
17
|
-
require 'calabash-cucumber/launcher'
|
18
|
-
|
19
|
-
|
20
|
-
# APP_BUNDLE_PATH = "#{ENV['HOME']}/Library/Developer/Xcode/DerivedData/??/Build/Products/Calabash-iphonesimulator/??.app"
|
21
|
-
# You may uncomment the above to overwrite the APP_BUNDLE_PATH
|
22
|
-
# However the recommended approach is to let Calabash find the app itself
|
23
|
-
# or set the environment variable APP_BUNDLE_PATH
|
24
|
-
|
25
|
-
|
26
|
-
Before do |scenario|
|
27
|
-
@calabash_launcher = Calabash::Cucumber::Launcher.new
|
28
|
-
unless @calabash_launcher.calabash_no_launch?
|
29
|
-
@calabash_launcher.relaunch
|
30
|
-
@calabash_launcher.calabash_notify(self)
|
31
|
-
end
|
32
|
-
end
|
33
|
-
|
34
|
-
After do |scenario|
|
35
|
-
unless @calabash_launcher.calabash_no_stop?
|
36
|
-
calabash_exit
|
37
|
-
if @calabash_launcher.active?
|
38
|
-
@calabash_launcher.stop
|
39
|
-
end
|
40
|
-
end
|
41
|
-
end
|
42
|
-
|
43
|
-
at_exit do
|
44
|
-
launcher = Calabash::Cucumber::Launcher.new
|
45
|
-
if launcher.simulator_target?
|
46
|
-
launcher.simulator_launcher.stop unless launcher.calabash_no_stop?
|
47
|
-
end
|
48
|
-
end
|