葫芦无法连接到模拟器

Calabash can't connect to simulator

我正在尝试 运行 在我的应用程序中进行一些 Calabash UI 测试,但 运行 在连接到我的模拟器时遇到了麻烦。我正在尝试连接查看 calabash-ios 控制台,但 运行 遇到以下错误:

 WARNING

Warning Trying to connect to simulator that was not launched by Calabash/instruments.
To fix this you must let Calabash or instruments launch the app.
Query will work, but gestures will not.

我已经 运行 应用程序查看我的 -cal 目标并成功看到消息 Started LPHTTP server on port 37265。以下是有关 Calabash/my 设置的更多信息:

xcode-select --print-path
/Applications/Xcode.app/Contents/Developer

xcodebuild -version
Xcode 7.0
Build version 7A218

calabash-ios version
0.14.3

server_version
=> {"app_id"=>"com.solstice.discoverfinancialenterprise.mobile", "outcome"=>"SUCCESS", "server_port"=>37265, "version"=>"0.14.3", "app_name"=>"Discover", "system"=>"x86_64", "simulator_device"=>"iPhone", "simulator"=>"", "app_version"=>"1", "short_version_string"=>"6.6.1 UAT", "iphone_app_emulated_on_ipad"=>false, "app_base_sdk"=>"iphonesimulator9.0", "form_factor"=>"iphone 4in", "git"=>{"revision"=>"c2d009b", "remote_origin"=>"git@github.com:calabash/calabash-ios-server.git", "branch"=>"master"}, "screen_dimensions"=>{"sample"=>1, "height"=>1136, "width"=>640, "scale"=>2}, "4inch"=>true, "iOS_version"=>"8.4"}

抱歉 JSON 没有格式化,我的控制台以未格式化的方式输出它。

我使用了几个不同的模拟器,iPhone 6、iOS 9 和 iOS 8.3,以及 iPhone 5s iOS 8.4。有谁知道我需要做些什么才能让它连接到我的模拟器?

+100 包含有关您的环境的所有信息。

请更新到与您的 Xcode 版本兼容的 Calabash 0.16.4。

I'm trying to just connect view the calabash-ios console, but am running into the following error:

你能展示一下你是如何启动控制台的以及你尝试执行什么命令的吗运行?

通常,您需要这样的东西:

$ APP=/path/to/Your.app calabash-ios console
> start_test_server_in_background

您必须让 calabash 启动应用程序,否则您将无法执行手势。

APP 和 APP_BUNDLE_PATH 是同义词。

http://calabashapi.xamarin.com/ios/file.ENVIRONMENT_VARIABLES.html#label-APP+and+APP_BUNDLE_PATH