calabash

How to Add Calabash to React Native iOS for Xamarin.UITest

元气小坏坏 提交于 2019-12-06 11:58:39
How can I add the Calabash Framework to an iOS app built in React Native? We are moving the codebase of our iOS app from Swift to React Native, and I have an existing suite of UITests built in C# using Xamarin.UITest. I'd like to continue using my Xamarin.UITest suite for the React Native iOS app, but I know that Xamarin.UITest requires the Calabash framework to be linked in the app's source code. Xamarin has documentation on how to link Calabash for an iOS app built in Xcode, but I cannot find any documentation on how to link Calabash for an iOS app built in React Native. Is there any similar

With Calabash for Android, how can write a step that scrolls to and touchs a specific listview row?

∥☆過路亽.° 提交于 2019-12-06 09:33:23
问题 I want to write a Cucumber step definition that scrolls to and selects a specific row in an Android ListView. On iOS I can do the following: scroll_to_cell(:row => 1, :section => 0) touch("tableViewCell indexPath:1,0") How would I do the same thing on Android? Update : In the calabash-android source, I've found a function called each_item which iterates over every item in a list view. However, I can't quite figure out how it would be valuable yet since it only returns an integer for it's

Get color of an element using calabash-android

﹥>﹥吖頭↗ 提交于 2019-12-06 09:28:57
问题 I have a text field(EditView) in my Android app, which changes color (borders) if it's value is not valid or empty. Also label(TextView) changes its color too in this case. When I'm trying to get TextView using query , I see the following: [0] { "id" => "field_lable", "enabled" => true, "contentDescription" => nil, "class" => "android.widget.TextView", "text" => "Name", "rect" => { "center_y" => 198.5, "center_x" => 51.0, "height" => 27, "y" => 185, "width" => 82, "x" => 10 }, "description" =

Getting “App did not start (RuntimeError)” when trying to run calabash-android tests on device

可紊 提交于 2019-12-06 03:47:10
问题 I'm trying to run an small initial set of calabash-android tests on a Samsung Galaxy S3 connected to a Windows 7 laptop and keep getting an "App did not start (RuntimeError)" when trying to start the test server. I've got Ruby v1.9.3p448, RubyDevKit 4.5.2 (32-bit), Ant 1.9.2, and AnsiCon installed. I've installed calabash-android 0.4.20 and all its dependent gems by typing "gem install calabash-android" at the command prompt. I've created a signed APK using Xamarin Studio and the release

cannot load such file — 2.2/gherkin_lexer_en, how to fix?

三世轮回 提交于 2019-12-05 22:25:40
I need a little help. How do I resolve this problem? When I call cucumber I get the following error: *** WARNING: You must use ANSICON 1.31 or higher (https://github.com/adoxa/ansic on/) to get coloured output on Windows WARNING: cannot load such file -- 2.2/gherkin_lexer_en Couldn't load 2.2/gherkin_lexer_en The $LOAD_PATH was: lib C:/Ruby22/lib/ruby/gems/2.2.0/gems/cucumber-1.3.19/bin/../lib C:/Ruby22/lib/ruby/gems/2.2.0/gems/builder-3.2.2/lib C:/Ruby22/lib/ruby/gems/2.2.0/gems/diff-lcs-1.2.5/lib C:/Ruby22/lib/ruby/gems/2.2.0/gems/multi_json-1.11.0/lib C:/Ruby22/lib/ruby/gems/2.2.0/gems

How to override a Calabash predefined step?

人走茶凉 提交于 2019-12-05 14:29:13
I'm defining custom calabash steps (to use on both iOS and Android) and would like to selectively override various predefined steps. An example is: Given /^I press the "([^\"]*)" button$/ do |text| tap_when_element_exists("android.widget.Button {text CONTAINS[c] '#{text}'}") end Instead of using this implementation, I would like to provide my own. If I define and use a step with a matching regex I get an error: Ambiguous match of "I press the "big red" button" It also suggests using "--guess" but that didn't help, and I still get the Cucumber::Ambiguous error. I could make some arbitrary

Jenkins multiconfiguration project handle concurrent device usage

限于喜欢 提交于 2019-12-05 11:10:20
Case I have a Jenkins slave witch run's calabash tests on mobile devices (android, ios). To separate on which machines (the mac for iOS or Linux for Android) the tests is run, I also use the Throttle Concurrent Builds Plug-in . This way I separate between the Android or Mac Jenkins slaves the devices are hooked to. I use a mapping table and a self written bash script to call a device by name and execute a test on this specific slave. The mapping table map's the name to the device id (or IP for iOS). The architecture is as follows: [Master]--(Slave-iOS)---------iPhone6 | |--------------iPhone5

Calabash iOS: how to get value using query command

烈酒焚心 提交于 2019-12-05 07:22:44
问题 I'm trying to get the value of every class using query command. Below is the sample UI component that I get: [0] { "class" => "UITabBarSwappableImageView", "id" => "imageView-34", "rect" => { "center_x" => 288, "y" => 522, "width" => 48, "x" => 264, "center_y" => 538, "height" => 32 }, "frame" => { "y" => 2, "width" => 48, "x" => 6, "height" => 32 }, "label" => nil, "description" => "<UITabBarSwappableImageVie....>" On Android, I can just use this to list all the values of class components:

Get color of an element using calabash-android

痴心易碎 提交于 2019-12-04 18:14:07
I have a text field(EditView) in my Android app, which changes color (borders) if it's value is not valid or empty. Also label(TextView) changes its color too in this case. When I'm trying to get TextView using query , I see the following: [0] { "id" => "field_lable", "enabled" => true, "contentDescription" => nil, "class" => "android.widget.TextView", "text" => "Name", "rect" => { "center_y" => 198.5, "center_x" => 51.0, "height" => 27, "y" => 185, "width" => 82, "x" => 10 }, "description" => "android.widget.TextView@a28btb00" } If i need to get text I can use query("TextView id:'field_label'

With Calabash for Android, how can write a step that scrolls to and touchs a specific listview row?

廉价感情. 提交于 2019-12-04 16:39:34
I want to write a Cucumber step definition that scrolls to and selects a specific row in an Android ListView. On iOS I can do the following: scroll_to_cell(:row => 1, :section => 0) touch("tableViewCell indexPath:1,0") How would I do the same thing on Android? Update : In the calabash-android source, I've found a function called each_item which iterates over every item in a list view. However, I can't quite figure out how it would be valuable yet since it only returns an integer for it's position in the listview as opposed to the item itself. So, I can't do something like... each_item do