cs-bdd 0.1.1 → 0.1.2

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: e520c9c43c7d3a85a0caa2b8f9ab6a906de0e882
4
- data.tar.gz: bf35813d182a41587e491050199114e8de3e0381
3
+ metadata.gz: 782f256dd4f8fe8b62f8958790dd3411383aee3e
4
+ data.tar.gz: 7eb26ef8870aa9dc2cd2853f4b2aefbc06c6a873
5
5
  SHA512:
6
- metadata.gz: be9e5f19148f6d64b59cc4142a209168bd590f54a6ad5cb7674b9d9b691d543779d18717d71f878c0c9436d379bd469a3f9a5b487cc6ae58116200b31b430783
7
- data.tar.gz: 241a8fd3ff44a757bb1e36a82a6d51c9b006740cef07839d5a560e9acc2220b850a90dab9d09651bc4e5ee53a83af9f73955c9d464834d244668b6c9b4128c84
6
+ metadata.gz: 233fa3aa05454750be186319d4d4078151a68a1ac9879e8bb763f422bc6437881edc02375f8431b829815c86ce557303de6aa6c602e0f1aa9b418ac389c81206
7
+ data.tar.gz: 39c35ee90e150fa6e086a6bb7bd6eeb235d030dccaaf4792e14f6d04804ed454f186b3c262e04ee68bb6ee1b73fbe24577aeafcfde3cc64847d4acbbf5346388
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # CS::BDD
2
2
 
3
- A simple gem to generate all the files needed to create a project that will support calabash for Android and iOS.
3
+ A simple gem to generate all files needed in a project that will support calabash for both Android and iOS.
4
4
 
5
5
  [Calabash](http://calaba.sh/) uses cucumber to support functional tests in Android and iOS and has one gem for each Platform:
6
6
 
@@ -8,15 +8,15 @@ A simple gem to generate all the files needed to create a project that will supp
8
8
 
9
9
  > calabash-cucumber (for iOS) [(link)](https://github.com/calabash/calabash-ios)
10
10
 
11
- The project structure is based on [this site](http://rubygemtsl.com/2014/01/06/designing-maintainable-calabash-tests-using-screen-objects-2). This structure is based on three layers: the features, the steps and the screens.
11
+ The project structure is based on [this site](http://rubygemtsl.com/2014/01/06/designing-maintainable-calabash-tests-using-screen-objects-2). The structure is based on three layers: features, steps and screens.
12
12
 
13
- 1. Features: Contains all the features of the project, this features are Platform independent and will run when testing both Android and iOS;
14
- 2. Steps: Contains all the steps implementation of the features. This steps are Platform independent and will run when testing both Android and iOS;
15
- 3. Screens: Contains all the screens definition. A screen definition must contain an identification, the declaration of all the elements of the screen and the declaration of its actions. This layer is Platform dependent. This occurs because, in almost every project, the identification of the elements of the screens varies between the Platforms. One example is that in Android almost all elements have an id, but in iOS is most common to identify the elements by accessibility label. The Platform dependent screens must has the same name and same methods. This will allow your steps to be unique between platforms
13
+ 1. Features: Contains all the features of the project, this features are Platform independent and will run for Android and iOS tests;
14
+ 2. Steps: Contains all the steps implementations. This steps are Platform independent and will run for Android and iOS tests;
15
+ 3. Screens: Contains all the Android and iOS screens. A screen must contain an identification, the declaration of all the elements of the screen and the declaration of its actions. This layer is Platform dependent. This occurs because, in almost every project, the identification of the elements varies between the Platforms. One example is that in Android almost all elements have an id, but in iOS the most common is to identify the elements by accessibility label. The Platform dependent screens must have the same name and same methods signatures. This will allow your steps to be unique between platforms
16
16
 
17
17
  > One example of this structure can be found in the generated files (see Usage) on the file base_steps.rb. This file implements some common steps to help you start your tests and show you how to uses the Platform dependent screens
18
18
 
19
- > In my experience with tests I saw some cases that we will need to test features that are Platform dependent, like screens that send SMS which will only happen in Android. For this to happen, the generated structure has Features and Steps that are Platform dependent and can be found inside the folder `features/android` and `features/ios` of the generated project.
19
+ > In my experience with tests I saw some cases that we will need to test features that are Platform dependent, like screens that send SMS which will only apper in Android apps. When this happen, the generated structure has Features and Steps that are Platform dependent and can be found inside the folder `features/android` and `features/ios` of the generated project.
20
20
 
21
21
  ## Installation
22
22
 
@@ -26,7 +26,7 @@ Install it as:
26
26
 
27
27
  ## Usage
28
28
 
29
- This gem works only in the terminal, so for help, type:
29
+ In the terminal, type for help:
30
30
 
31
31
  ```
32
32
  cs-bdd
@@ -39,70 +39,89 @@ To see the gem version type:
39
39
  cs-bdd version
40
40
  ```
41
41
 
42
- To generate a structure of one project that can support both Android and iOS features for Calabash type:
42
+ To generate a project that support both Android and iOS features type:
43
43
 
44
44
  ```
45
45
  cs-bdd new ProjectName
46
46
  ```
47
47
 
48
- This command will create a folder named ProjectName in the current directory and will create all the files needed. This gem support localizations. To create a localized project, in Portuguese, type:
48
+ This command will create a folder named ProjectName in the current directory and will create all the needed files. This gem support localizations. To create a localized project, in Portuguese, type:
49
49
 
50
50
  ```
51
51
  cs-bdd new ProjectName --lang=pt
52
52
  ```
53
53
 
54
- > The default language is English ('en'). The elements of Gherkin such as Given, When, Than, And, Scenario will be translated to all Gherkin supported languages, but the generators accept only a little quantity of languages(see than in the folder: `lib/cs/bdd/locales`).
54
+ > The default language is English ('en'). The elements of Gherkin such as Given, When, Than, And, Scenario will be translated to all Gherkin supported languages, but this gem has a little quantity of translation files (see than in folder: `lib/cs/bdd/locales`).
55
55
 
56
- > **CS-BDD doesn't support your mother language?** No problem make a fork, create your yml translation file, uses the en.yml file as a template. Translate it and make a pull request. There are only 15 lines to be translated, this will take no time.
56
+ > **CS-BDD doesn't support your mother language?** No problem. Fork it, create your yml translation file, uses the en.yml file as a template. Translate it and make a pull request. There are only 15 lines to be translated, this will take no time.
57
57
 
58
- > **Don't know how to identify your yml file?** See the Gherkin supported languages [here](https://github.com/cucumber/gherkin/blob/master/lib/gherkin/i18n.json).
58
+ > **Don't you know how to name your translation yml file?** See the Gherkin supported languages [here](https://github.com/cucumber/gherkin/blob/master/lib/gherkin/i18n.json) for reference.
59
59
 
60
- Once the project is created, opens the folder (`cd ProjectName`).
60
+ Once the project is created, open its folder (`cd ProjectName`).
61
+
62
+
63
+ **The generators commands ONLY WORK in the ROOT FOLDER of the project**.
61
64
 
62
- > **The generators commands ONLY WORK in the ROOT FOLDER of the project**.
63
65
 
64
66
  There are nine generators that are responsible to create the templates for Features, Step definitions and Screens.
65
67
 
66
- For Features you can type:
68
+ ####Features
67
69
 
68
70
  ```
69
71
  cs-bdd generate feature FeatureName
72
+ ```
73
+ The feature generator will create a Platform independent feature and its files. So this command will create the FeatureName.feature file inside the folder `feature`, the file FeatureName_steps.rb inside the folder `features/step_definitions`, the files FeatureName_screen.rb inside the folders `features/android/screens` and `features/ios/screens`.
74
+
75
+
76
+ ```
70
77
  cs-bdd generate aFeature AndroidFeatureName
71
78
  cs-bdd generate iFeature iOSFeatureName
72
79
  ```
80
+ The aFeature and iFeature generator will create an Platform dependent feature. For example, the aFeature generator will create the AndroidFeatureName.feature file inside the folder `features/android/features`, the file AndroidFeatureName_steps.rb inside the folder `features/androd/step_definitions` and the screen file AndroidFeatureName_screen.rb inside the folder `features/android/screens`.
73
81
 
74
- > The feature generator will create a Platform independent feature and its files. So this command will create the FeatureName.feature file in the folder `feature`, the file FeatureName_steps.rb in the folder `features/step_definitions`, the the files FeatureName_screen.rb in the folders `features/android/screens` and `features/ios/screens`.
75
-
76
- > The aFeature and iFeature generator will create and Platform dependent feature so, for example, the aFeature generator will create the AndroidFeatureName.feature file in the folder `features/android/features`, the file AndroidFeatureName_steps.rb in the folder `features/androd/step_definitions` and the screen file AndroidFeatureName_screen.rb in the folder `features/android/screens`.
77
82
 
78
83
  Don't forget about internationalization. All the generators accept the option `--lang=pt` or with some other language.
79
84
 
80
- For Steps definitions you can type:
85
+ ####Steps
81
86
 
82
87
  ```
83
88
  cs-bdd generate step StepName
89
+ ```
90
+ The step generator will create a Platform independent step file named StepName_steps.rb in the folder `features/step_definitions`
91
+
92
+
93
+ ```
84
94
  cs-bdd generate aStep AndroidStepName
95
+ ```
96
+ The aStep generator will create an Android step file named AndroidStepName_steps.rb in the folder `features/android/step_definitions`
97
+
98
+
99
+ ```
85
100
  cs-bdd generate iStep iOSStepName
86
101
  ```
102
+ The iStep generator will create an iOS step file name iOSStepName_steps.rb in the folder `features/ios/step_definitions`
103
+
87
104
 
88
- > The step generator will create a Platform independent step file named StepName_steps.rb in the folder `features/step_definitions`
89
-
90
- > The aStep generator will create an Android step file named AndroidStepName_steps.rb in the folder `features/android/step_definitions`
91
-
92
- > The iStep generator will create an iOS step file name iOSStepName_steps.rb in the folder `features/ios/step_definitions`
93
105
 
94
- For Screens type:
106
+ ####Screens
95
107
 
96
108
  ```
97
109
  cs-bdd generate screen ScreenName
110
+ ```
111
+ The screen generator will create both Platform dependent screens in the folders `features/android/screens` and `features/ios/screens`.
112
+
113
+
114
+ ```
98
115
  cs-bdd generate aScreen AndroidScreenName
99
116
  cs-bdd generate iScreen iOSScreenName
100
117
  ```
118
+ The aScreen and iScreen will create only the Android and iOS dependent screens respectively.
101
119
 
102
- > The screen generator will create both Platform dependent screens in the folders `features/android/screens` and `features/ios/screens`.
103
-
104
- > The aScreen and iScreen will create only the Android and iOS dependent screens respectively.
120
+ ## Continuous Integration (CI)
121
+
122
+ The project contains a lot of scripts that will help you to configure you CI server.
105
123
 
124
+ > Documentation under development.
106
125
 
107
126
  ## Contributing
108
127
 
@@ -110,4 +129,4 @@ For Screens type:
110
129
  2. Create your feature branch (`git checkout -b my-new-feature`)
111
130
  3. Commit your changes (`git commit -am 'Add some feature'`)
112
131
  4. Push to the branch (`git push origin my-new-feature`)
113
- 5. Create a new Pull Request
132
+ 5. Create a new Pull Request
data/bin/cs-bdd CHANGED
@@ -122,7 +122,14 @@ module CS
122
122
  directory File.join( File.dirname(__FILE__), '..', 'lib', 'skeleton' ), name
123
123
 
124
124
  # Copying base steps file with localization
125
- template( "base_steps", File.join(name, 'features', 'step_definitions', 'base_steps.rb') )
125
+ template( "base_steps", File.join(name, 'features', 'step_definitions', 'base_steps.rb' ) )
126
+
127
+ # Copying android screen base file with localization
128
+ template( "android_screen_base", File.join(name, 'features', 'android', 'android_screen_base.rb' ) )
129
+
130
+ # Copying ios screen base file with localization
131
+ template( "ios_screen_base", File.join(name, 'features', 'ios', 'ios_screen_base.rb' ) )
132
+
126
133
  end
127
134
 
128
135
  desc "version", "Shows the gem version"
@@ -156,4 +163,4 @@ module CS
156
163
  end
157
164
  end
158
165
 
159
- CS::BDD::CsBddRunner.start
166
+ CS::BDD::CsBddRunner.start
@@ -18,9 +18,10 @@ Gem::Specification.new do |spec|
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ["lib"]
20
20
 
21
- spec.add_development_dependency "bundler", "~> 1.7"
22
- spec.add_development_dependency "rake", "~> 10.0"
23
- spec.add_development_dependency "thor", "~> 0.19.1"
24
- spec.add_development_dependency "i18n", "~> 0.6.11"
25
- spec.add_development_dependency "gherkin", "~> 2.12.2"
21
+ spec.add_runtime_dependency "bundler", "~> 1.7"
22
+ spec.add_runtime_dependency "rake", "~> 10.0"
23
+ spec.add_runtime_dependency "thor", "~> 0.19.1"
24
+ spec.add_runtime_dependency "i18n", "~> 0.6.11"
25
+ spec.add_runtime_dependency "gherkin", "~> 2.12.2"
26
+
26
27
  end
@@ -8,11 +8,16 @@ en:
8
8
  elements: "Declare all the elements of this screen"
9
9
  actions: "Declare all actions of this screen"
10
10
  steps:
11
- drag_until: "I (?:drag|dragged) the screen (down|up|left|right) until I see the element"
12
- page_contains: "I am on a page that contains"
11
+ drag_until: 'I (?:drag|dragged) the screen (down|up|left|right) until I see the element "(.*?)"'
12
+ page_contains: "I am on a page that contains '(.*?)'"
13
13
  drag_number_of_times: 'I drag the screen (left|right|down|up) (\d+) times'
14
14
  touch_element: 'I (?:touch|touched) the "(.*?)" element'
15
15
  drag_screen: "I drag the screen (down|up|left|right)"
16
16
  wait_progress_bar: "I (?:wait|waited) for the progress bar to vanish"
17
- should_see_page: "I should see the page"
18
- should_see_page_that_contains: "I should see a page that contains"
17
+ should_see_page: "I should see the page '(.*?)'"
18
+ should_see_page_that_contains: "I should see a page that contains '(.*?)'"
19
+ directions:
20
+ up: 'up'
21
+ down: 'down'
22
+ left: 'left'
23
+ right: 'right'
@@ -8,11 +8,16 @@ pt:
8
8
  elements: "Declare todos os elementos da tela"
9
9
  actions: "Declare todas as ações da tela"
10
10
  steps:
11
- drag_until: "que Eu (?:arrastei|arrasto) a tela para (baixo|cima|esquerda|direita) até ver o elemento"
12
- page_contains: "que Eu estou em uma página que contem"
11
+ drag_until: 'que Eu (?:arrastei|arrasto) a tela para (baixo|cima|esquerda|direita) até ver o elemento "(.*?)"'
12
+ page_contains: "que Eu estou em uma página que contem '(.*?)'"
13
13
  drag_number_of_times: 'Eu arrasto a tela para (esquerda|direita|baixo|cima) (\d+) vezes'
14
14
  touch_element: 'Eu (?:clico|cliquei) no elemento "(.*?)"'
15
15
  drag_screen: "Eu arrasto a tela para (baixo|cima|esquerda|direita)"
16
- wait_progress_bar: "Eu (?:espero|esperei) até a barar de progresso sumir"
17
- should_see_page: "Eu deveria ver a página"
18
- should_see_page_that_contains: "Eu deveria ver uma página que contem"
16
+ wait_progress_bar: "Eu (?:espero|esperei) até a barra de progresso sumir"
17
+ should_see_page: "Eu deveria ver a página '(.*?)'"
18
+ should_see_page_that_contains: "Eu deveria ver uma página que contem '(.*?)'"
19
+ directions:
20
+ up: 'cima'
21
+ down: 'baixo'
22
+ left: 'esquerda'
23
+ right: 'direita'
@@ -1,5 +1,5 @@
1
1
  module CS
2
2
  module BDD
3
- VERSION = "0.1.1"
3
+ VERSION = "0.1.2"
4
4
  end
5
5
  end
@@ -24,14 +24,13 @@
24
24
  Install the following gems
25
25
 
26
26
  ```
27
- gem install calabash-common
28
- gem install calabash-android
27
+ gem install calabash-common calabash-android
29
28
  ```
30
29
 
31
30
  **Warning!**
32
31
 
33
- The command **`gem install calabash-android`** installs the beta version of the cucumber gem.
34
- This gem brokes the execution of the calabash. After the installation of calabash-android, install the stable version of the cucumber gem (command: `gem install cucumber`) and remove the beta version (command: `gem uninstall cucumber`).
32
+ The gem **`calabash-android`** can install the beta version of the cucumber gem.
33
+ This gem brokes the execution of the calabash. After the installation of calabash-android, check your installed gems with the command `gem list | grep cucumber` and install the stable version of the cucumber gem (command: `gem install cucumber`) and remove the beta version (command: `gem uninstall cucumber`), if that is the case.
35
34
 
36
35
  ## Running the tests
37
36
  To run the android tests, you need to:
@@ -96,8 +95,7 @@ To open the calabash terminal, you need to:
96
95
  Install the following gems
97
96
 
98
97
  ```
99
- gem install calabash-common
100
- gem install calabash-cucumber
98
+ gem install calabash-common calabash-cucumber
101
99
  ```
102
100
 
103
101
  ## Configuring the iOS project
@@ -0,0 +1,16 @@
1
+ <html>
2
+ <head>
3
+ <meta charset="UTF-8">
4
+ <title>Project Name - BDD _OS_ - _STATUS_TITLE_</title>
5
+ </head>
6
+ <body>
7
+ <center>
8
+ <font face="Trebuchet MS" size="3">
9
+ <h1>Continuous Integration</h1>
10
+ <h2>Job Status: _JOB_NAME_, build number: #_BUILD_NUMBER_</h2>
11
+ Hello. I'm here to let you know that the tests <strong>_STATUS_</strong>.<br>
12
+ To view the reports, click <a href="http://jenkins_url/reports/_JOB_NAME_/_BUILD_NUMBER_">here.</a><br>
13
+ </font>
14
+ </center>
15
+ </body>
16
+ </html>
@@ -4,32 +4,38 @@
4
4
  # set -x
5
5
  #
6
6
  # $1 -> parameter with the name of the apk
7
-
7
+ # $2 -> parameter to indicates the tapume to run. Can be null and can have other 2 values: must or should
8
8
 
9
9
  ## CODE BEGIN #############################################################
10
- [ $# -ne 1 ] && echo "Wrong number of parameters." && exit 1
10
+ [ $# -lt 1 ] && echo "Wrong number of parameters." && exit 1
11
+
12
+ # Counting the number of lines returned from the command adb devices
13
+ # This command will return at least 2 as result, because of one header line and one empty line at end
14
+ # So if the result is less than or equal 2, it means that there are no devices or emulators connected
15
+ number_of_devices=$(adb devices | wc -l)
16
+ [ $number_of_devices -le 2 ] && echo "There are no devices or emulators connected!" && exit 1
11
17
 
12
18
  echo Inicio da execução: $(date)
13
19
 
14
- reports_path="/var/www/html/reports/$(date +"%Y%d%m")"
20
+ # Creating the reports folder for the html format
21
+ reports_path="$WORKSPACE/reports-cal"
22
+ mkdir $reports_path
15
23
 
16
24
  for device in $(adb devices | grep "device$" | cut -f 1)
17
25
  do
18
- rm -r "$reports_path"/"$device" &> /dev/null
19
- mkdir -p "$reports_path"/"$device" &> /dev/null
20
- echo $device | grep -q emulator
21
- # SET THE IGNORE TAGS TRUE IF THE TEST ARE RUNNING IN A DEVICE
22
- [ $? -ne 0 ] && ignore='--tags ~@ignore_if_test_in_device'
23
26
  cd $WORKSPACE
24
- ADB_DEVICE_ARG=$device SCREENSHOT_PATH="$reports_path"/"$device"/ calabash-android run $1 -p android --format 'Calabash::Formatters::Html' --out "$reports_path"/"$device"/reports.html $ignore &
27
+ # Creates the reports folder
28
+ mkdir "$reports_path"/"$device"
29
+
30
+ {
31
+ ADB_DEVICE_ARG=$device SCREENSHOT_PATH="$reports_path"/"$device"/ calabash-android run $1 -p android -f 'Calabash::Formatters::Html' -o "$reports_path"/"$device"/reports.html -f junit -o "$reports_path"/"$device"
32
+ # Calabash has a problem with images relative path, the command above will replace all the images path on the
33
+ # html report file to be a relative path
34
+ sed -i.bak 's|'"$reports_path"/"$device"/'||g' "$reports_path"/"$device"/reports.html
35
+ }&
36
+
25
37
  done
26
38
  wait
27
39
 
28
- # Calabash has a problem with images relative path, the command above will replace all the images path on the
29
- # html report file to be a relative path
30
- for device in $(adb devices | grep "device$" | cut -f 1)
31
- do
32
- sed -i 's|'"$reports_path"/"$device"/'||g' "$reports_path"/"$device"/reports.html
33
- done
34
40
  echo Fim da execução: $(date)
35
41
  ## CODE END #############################################################
@@ -0,0 +1,52 @@
1
+ #!/bin/bash
2
+ # Author: Victor Nascimento
3
+
4
+ bash stop_emulators.sh
5
+
6
+ # Suffix name of the AVD
7
+ SUFFIX="CALABASH_AVD_4."
8
+
9
+ # All $SUFFIX emulators are started
10
+ for AVD in ${HOME}/.android/avd/${SUFFIX}*.avd
11
+ do
12
+ # remove any locks that were left
13
+ rm "$AVD/*.lock" 2> /dev/null
14
+ # takes only the name of the AVD
15
+ echo $AVD
16
+ AVD="$(basename ${AVD/.avd/})"
17
+ echo starting "$AVD"...
18
+ emulator -gpu on -noaudio -scale 0.5 -no-boot-anim -accel on -avd "$AVD" -qemu -m 1024 -enable-kvm &
19
+ done
20
+
21
+ sleep 15
22
+ # lists all emulators with adb and check for its online state
23
+
24
+ # finds the port through adb emulator name
25
+ for porta in $(adb devices -l | grep ^emulator | cut -d " " -f 1 | cut -d - -f 2)
26
+ do
27
+ echo Searching for emulator PID for port: ${porta}
28
+ pid=$(netstat -tlnp 2> /dev/null | grep "$porta" | tr -s " " | cut -d " " -f 7 | cut -d "/" -f 1)
29
+ echo gets the AVD name from the exec command
30
+ avd=$(ps -ef | grep -v grep | grep "$pid" | egrep -o '\-avd .*' | cut -d " " -f 2)
31
+ echo AVD: ${avd}
32
+ # if name contains suffix
33
+ if echo "$avd" | grep -q "$SUFFIX"
34
+ then
35
+ echo Waiting for "emulator-${porta}:${avd}" to be ready
36
+
37
+ # Wait for online state with maximum 60 tries
38
+ COUNT=0
39
+
40
+ while adb -s "emulator-${porta}" shell getprop dev.bootcomplete | grep -q error
41
+ do
42
+ if [ "$COUNT" -eq 60 ]
43
+ then
44
+ echo "Emulator took too long to start up"
45
+ exit 1
46
+ fi
47
+
48
+ let COUNT++
49
+ sleep 1
50
+ done
51
+ fi
52
+ done
@@ -0,0 +1,13 @@
1
+ #!/bin/bash
2
+ # Author: Victor Nascimento
3
+
4
+ SUFFIX=CALABASH_AVD_4.
5
+
6
+ for AVD in $HOME/.android/avd/${SUFFIX}*.avd
7
+ do
8
+ AVD="$(basename ${AVD/.avd/})"
9
+ echo chuck killing "$AVD"...
10
+ pkill -9 -f "$AVD"
11
+ done
12
+
13
+
@@ -0,0 +1,6 @@
1
+ # Looking for errors on the report files and returns an error
2
+ if [ $TESTS_RESULT == "Failed" ]
3
+ then
4
+ echo "Setting build as failed"
5
+ exit 1
6
+ fi
@@ -0,0 +1,13 @@
1
+ # Looking for errors on the report files and returns an error
2
+ cd "$WORKSPACE/reports-cal"
3
+ export TESTS_RESULT=""
4
+ for folder in *
5
+ do
6
+ if egrep '\([0-9]+ passed\)' "$folder/reports.html"
7
+ then
8
+ [ "$TESTS_RESULT" == "Failed" ] && continue
9
+ export TESTS_RESULT="Ok"
10
+ else
11
+ export TESTS_RESULT="Failed"
12
+ fi
13
+ done
@@ -9,6 +9,7 @@
9
9
  # When this script was created the available sdks were: 'iphoneos8.1' for
10
10
  # devices and iphonesimulator8.1 for simulator
11
11
  # $4 -> Configuration type. Ex.: 'Dev'
12
+ # $5 -> The path to save the .app bundle
12
13
 
13
14
  ## CODE BEGIN #############################################################
14
15
 
@@ -17,22 +18,25 @@
17
18
  # building problems
18
19
  # pod install
19
20
 
20
- [ $# -ne 4 ] && echo "Wrong number of parameters." && exit 1
21
+ [ $# -ne 5 ] && echo "Wrong number of parameters." && exit 1
21
22
 
22
- echo "Building project for calabash"
23
+ echo Inicio da execução: $(date)
24
+
25
+ # Creating .app bundle path folder if it doesn't exists
26
+ mkdir -p "$5"
23
27
 
24
- xcodebuild -workspace "$1" -scheme "$2" -sdk "$3" -configuration "$4" clean build
28
+ # Changing relative to absolute path if that is the case
29
+ original_path="$(pwd)" # Saving the original path where the command was executed
30
+ cd "$5"
31
+ path="$(pwd)"
32
+ cd "$original_path" # Going back to the original path
25
33
 
26
- BUILT_PRODUCTS_DIR=`xcodebuild -workspace "$1" -scheme "$2" -sdk "$3" -showBuildSettings -configuration "$4" |
27
- grep -i "\bbuilt_products_dir" |
28
- cut -d "=" -f2 `
34
+ echo "Building project for calabash"
29
35
 
30
- export APP_BUNDLE_PATH=`echo "$BUILT_PRODUCTS_DIR/$2.app" |
31
- sed 's/^\ *//g' |
32
- sed 's/\ *$//g'`
36
+ xcodebuild -workspace "$1" -scheme "$2" -sdk "$3" -configuration "$4" clean build CONFIGURATION_BUILD_DIR="$path"
33
37
 
34
- echo $APP_BUNDLE_PATH
38
+ echo "APP_BUNDLE_PATH=$path/$2.app"
35
39
 
36
40
  echo End: $(date)
37
41
  echo 'Bye!'
38
- ## CODE END #############################################################
42
+ ## CODE END #############################################################
@@ -0,0 +1,4 @@
1
+ # <DEVICE_TARGET (UUID)> | <DEVICE_ENDPOINT (IP)> | <DEVICE_NAME> | <DEVICE_TYPE> (Simulator or Device)
2
+ 000...000 | http://localhost:37265 | Device0 | Simulator
3
+ 111...111 | http://1.1.1.1:37265 | Device1 | Device
4
+ # EOF - Never erase this comment or the script will have problems to read this file
@@ -3,45 +3,54 @@
3
3
  # Uncomment the next line to enable debug
4
4
  # set -x
5
5
  #
6
- # $1 -> parameter with the path of the .app bundle
6
+ # $1 -> parameter with the path of the .app bundle for simulators
7
+ # $2 -> parameter with the path of the .app bundle for devices
7
8
 
8
9
  ## CODE BEGIN #############################################################
9
10
 
10
11
  echo Start: $(date)
11
12
 
12
13
  # Exits if the app path was not informed
13
- if [ -z $1 ]; then
14
- echo "The first parameter must be the app path"
15
- exit 1
16
- fi
17
-
18
- # Remember to install an application server to enable remote access to the reports
19
- # Remember to previous create the reports folder and give the appropriate permissions
20
- reports_path="/var/www/reports/$(date +"%Y%d%m")"
21
-
22
- # Reads the devices file line by line
23
- while read line
24
- do
25
- # Ignoring all comments
26
- echo $line | grep -q "^#" && continue
27
-
28
- # Reading the informations of the device in the devices file
29
- # The variables can't contain any kind of spaces, so we erase then off
30
- target="$(echo $line | cut -d'|' -f1 | tr -d ' ')"
31
- endpoint="$(echo $line | cut -d'|' -f2 | tr -d ' ')"
32
- name="$(echo $line | cut -d'|' -f3 | tr -d ' ')"
33
-
34
- # Cleaning the previous reports folder and ensuring its existence
35
- rm -r "$reports_path"/"$name" &> /dev/null
36
- mkdir -p "$reports_path"/"$name" &> /dev/null
37
-
38
- # Navigating to the tests root folder
39
- cd "$WORKSPACE"
40
-
41
- # Executing calabash for the device
42
- APP_BUNDLE_PATH="$1" DEVICE_TARGET="$target" DEVICE_ENDPOINT="$endpoint" SCREENSHOT_PATH="$reports_path"/"$name"/ cucumber -p ios --format 'Calabash::Formatters::Html' --out "$reports_path"/"$name/reports.html"
43
-
44
- done < config/scripts/ios/devices
14
+ [ $# -lt 2 ] && echo "Wrong number of parameters." && exit 1
15
+
16
+ # Creating the reports path
17
+ reports_path="$WORKSPACE/reports-cal"
18
+ mkdir $reports_path
19
+
20
+ # Changing relative to absolute path if that is the case
21
+ # The simulator path
22
+ original_path="$(pwd)" # Saving the original path where the command was executed
23
+ cd "$1"
24
+ SIMULATOR_APP_PATH="$(pwd)"
25
+ # The device path
26
+ cd "$original_path"
27
+ cd "$2"
28
+ DEVICE_APP_PATH="$(pwd)"
29
+
30
+ cd $WORKSPACE # All tests should run from the root folder of the tests project
31
+
32
+ cat config/scripts/ios/devices.txt | ## Reading the devices.txt file
33
+ grep -v "#" | ## Removing the command lines
34
+ tr -d " " | ## Trimming all the spaces
35
+ while IFS='|' read UUID IP NAME TYPE ## Defining pipe as the separator char and reading the three variable fields
36
+ do
37
+ # Creating the report folder for this device or simulator
38
+ mkdir "$reports_path"/"$NAME"
39
+
40
+ if [ $TYPE == "Simulator" ]
41
+ then
42
+ APP_PATH=$SIMULATOR_APP_PATH
43
+ else
44
+ APP_PATH=$DEVICE_APP_PATH
45
+ fi
46
+
47
+ # Executing calabash for the device or simulator
48
+ APP_BUNDLE_PATH="$APP_PATH" DEVICE_TARGET="$UUID" DEVICE_ENDPOINT="$IP" SCREENSHOT_PATH="$reports_path"/"$NAME"/ cucumber -p ios -f 'Calabash::Formatters::Html' -o "$reports_path"/"$NAME/reports.html" -f junit -o "$reports_path"/"$NAME"
49
+
50
+ # Calabash has a problem with images relative path, the command above will replace all the images path on the
51
+ # html report file to be a relative path
52
+ sed -i.bak 's|'"$reports_path"/"$NAME"/'||g' "$reports_path"/"$NAME"/reports.html
53
+ done
45
54
 
46
55
  echo End: $(date)
47
56
  echo 'Bye!'
@@ -64,10 +64,9 @@ end
64
64
  # Install or reinstall the app on the device
65
65
  def reinstall_app
66
66
 
67
- # If test is in a device
68
- if( !ENV['APP_BUNDLE_PATH'].include?( "iphonesimulator" ) )
67
+ if !is_simulator? ENV['DEVICE_TARGET']
69
68
 
70
- system( "echo 'Installing the app...'" )
69
+ system "echo 'Installing the app...'"
71
70
 
72
71
  # Trying to reinstall the app
73
72
  success = system "ios-deploy -r -b #{ENV['APP_BUNDLE_PATH']} -i #{ENV['DEVICE_TARGET']} -t 5 > /dev/null"
@@ -81,29 +80,61 @@ def reinstall_app
81
80
  end
82
81
  end
83
82
 
84
- system( "echo 'Installed.'" )
83
+ system "echo 'Installed.'"
85
84
 
86
85
  sleep(3) # Gives to the iphone a time to finish the installation of the app
87
86
  else # If test is in a simulator
88
87
 
88
+ # Shutdown all the booted simulators to avoid problems with the switch of simulatores
89
+ # on the automated tests (like when on jenkins)
90
+ shutdown_booted_simulators
91
+
89
92
  # APP_BUNDLE_ID must be set in order to uninstall the app from the simulator
90
93
  # You can either pass it as a parameter in the cucumber command or set it here
91
94
  #ENV["APP_BUNDLE_ID"] = "bundle_id"
92
95
 
93
96
  # Booting the device to avoid problems with the app installation
94
- %x(open -a "iOS Simulator" --args -CurrentDeviceUDID #{ENV['DEVICE_TARGET']} > /dev/null)
97
+ %x(open -a 'iOS Simulator' --args -CurrentDeviceUDID #{ENV['DEVICE_TARGET']} > /dev/null)
95
98
  sleep(7)
96
99
 
97
100
  # Reinstalling the app using terminal commands
98
- system( "echo 'Installing the app...'" )
101
+ system "echo 'Installing the app...'"
99
102
 
100
103
  # Removing the app
101
- %x(xcrun simctl uninstall #{ENV['DEVICE_TARGET']} #{ENV["APP_BUNDLE_ID"]} > /dev/null)
104
+ %x(xcrun simctl uninstall #{ENV['DEVICE_TARGET']} #{ENV['APP_BUNDLE_ID']} > /dev/null)
102
105
 
103
106
  # Installing the app
104
107
  %x(xcrun simctl install #{ENV['DEVICE_TARGET']} #{ENV['APP_BUNDLE_PATH']} > /dev/null)
105
108
 
106
- system( "echo 'Installed.'" )
109
+ system "echo 'Installed.'"
110
+
111
+ end
112
+
113
+ end
114
+
115
+ # Checks if the UUID belongs to a Device or a Simulator
116
+ def is_simulator? uuid
117
+ # Check if UUID is from a device or a simulator
118
+ # Getting all the simulator's UUID
119
+ uuids = `xcrun simctl list`
120
+ return true if uuids.include? uuid
121
+ return false
122
+ end
123
+
124
+ # Kill all simulators process, lists all the booted simulators and shut them down
125
+ def shutdown_booted_simulators
107
126
 
127
+ # Closing all Simulators running
128
+ %x(killall "iOS Simulator")
129
+
130
+ # Listing all the booted devices
131
+ booted_simulators = `xcrun simctl list | grep 'Booted'`
132
+
133
+ # Getting the UUIDs
134
+ booted_simulators.split("\n").each do |simulator|
135
+ uuid = simulator.split("(")[1].gsub(")", "").gsub(" ","")
136
+ # Shuting the simulator down
137
+ %x(xcrun simctl shutdown #{uuid})
108
138
  end
139
+
109
140
  end
@@ -2,8 +2,8 @@ require 'calabash-android/abase'
2
2
 
3
3
  class AndroidScreenBase < Calabash::ABase
4
4
 
5
- def self.element element_name
6
- define_method element_name.to_s
5
+ def self.element(element_name, &block)
6
+ define_method(element_name.to_s, *block)
7
7
  end
8
8
 
9
9
  class << self
@@ -16,7 +16,7 @@ class AndroidScreenBase < Calabash::ABase
16
16
 
17
17
  # The progress bar of the application is a custom view
18
18
  def wait_for_progress
19
- wait_for_element_does_not_exist(loading_screen)
19
+ wait_for_element_does_not_exist("* id:'#{loading_screen}'", { :timeout => 10 } )
20
20
  end
21
21
 
22
22
  def drag_to direction
@@ -24,13 +24,13 @@ class AndroidScreenBase < Calabash::ABase
24
24
  positions = [0,0,0,0] # [ 'from_x', 'to_x', 'from_y', 'to_y' ]
25
25
 
26
26
  case(direction)
27
- when :down
27
+ when :<%= (I18n.translate "directions.down").to_sym %>
28
28
  positions = [30,30,60,30]
29
- when :up
29
+ when :<%= (I18n.translate "directions.up").to_sym %>
30
30
  positions = [80,80,60,90]
31
- when :left
31
+ when :<%= (I18n.translate "directions.left").to_sym %>
32
32
  positions = [90,20,80,80]
33
- when :right
33
+ when :<%= (I18n.translate "directions.right").to_sym %>
34
34
  positions = [20,90,80,80]
35
35
  end
36
36
 
@@ -69,12 +69,15 @@ class AndroidScreenBase < Calabash::ABase
69
69
  end
70
70
  end
71
71
 
72
- def is_on_page? page_text
73
-
72
+ # Negation indicates that we want a page that doesn't has the message passed as parameter
73
+ def is_on_page? page_text, negation = ''
74
74
  begin
75
- wait_for(:timeout => 5) { has_text? page_text }
75
+ wait_for(timeout: 5) { has_text? page_text }
76
+ # If negation is not nil, we should raise an error if this message was found on the view
77
+ raise "Unexpected Page. The page should not have: '${page_text}'" unless negation == ""
76
78
  rescue
77
- raise "Unexpected Page. Expected was: '#{page_text}'"
79
+ # only raise exception if negation is nil, otherwise this is the expected behaviour
80
+ raise "Unexpected Page. Expected was: '#{page_text}'" if negation == ""
78
81
  end
79
82
  end
80
83
 
@@ -86,9 +89,30 @@ class AndroidScreenBase < Calabash::ABase
86
89
  end
87
90
  end
88
91
 
92
+ def touch_screen_element element, query = nil
93
+ query = "* id:'#{element}'" if query.nil?
94
+ wait_for(timeout: 5) { element_exists(query) }
95
+ touch(query)
96
+ end
97
+
89
98
  def touch_element_by_index id, index
90
99
  wait_for(:timeout => 5) { element_exists("* id:'#{id}' index:#{index}") }
91
100
  touch("* id:'#{id}' index:#{index}")
92
101
  end
93
102
 
103
+ def clear_text_field field
104
+ clear_text_in("android.widget.EditText id:'#{field}'}")
105
+ end
106
+
107
+ def select_date_on_date_picker date, date_picker_field_id
108
+ # Touch the date picker field
109
+ touch "* id:'#{date_picker_field_id}'"
110
+
111
+ # Setting the date
112
+ set_date 'DatePicker', date.year, date.month, date.day
113
+
114
+ # Clicking in the Done button
115
+ touch "* id:'button1'"
116
+ end
117
+
94
118
  end
@@ -1,9 +1,9 @@
1
1
  ######### <%= I18n.translate( :given ).upcase %> #########
2
- <%= I18n.translate( :given ).capitalize %>(/^<%= I18n.translate( "steps.drag_until" ) %> "(.*?)"$/) do |direction, element|
2
+ <%= I18n.translate( :given ).capitalize %>(/^<%= I18n.translate( "steps.drag_until" ) %>$/) do |direction, element|
3
3
  @page.drag_until_element_is_visible_with_special_query direction.to_sym, element
4
4
  end
5
5
 
6
- <%= I18n.translate( :given ).capitalize %>(/^<%= I18n.translate( "steps.page_contais" ) %> '(.*?)'$/) do |page_text|
6
+ <%= I18n.translate( :given ).capitalize %>(/^<%= I18n.translate( "steps.page_contais" ) %>$/) do |page_text|
7
7
  @page.is_on_page? page_text
8
8
  end
9
9
 
@@ -29,10 +29,10 @@ end
29
29
  @page.wait_for_progress
30
30
  end
31
31
 
32
- <%= I18n.translate( :then ).capitalize %>(/^<%= I18n.translate "steps.should_see_page" %> '(.*?)'$/) do |page_text|
32
+ <%= I18n.translate( :then ).capitalize %>(/^<%= I18n.translate "steps.should_see_page" %>$/) do |page_text|
33
33
  @page.is_on_page? page_text
34
34
  end
35
35
 
36
- <%= I18n.translate( :then ).capitalize %>(/^<%= I18n.translate "steps.should_see_page_that_contains" %> '(.*?)'$/) do |page_text|
36
+ <%= I18n.translate( :then ).capitalize %>(/^<%= I18n.translate "steps.should_see_page_that_contains" %>$/) do |page_text|
37
37
  @page.is_on_page? page_text
38
38
  end
@@ -16,7 +16,7 @@ class IOSScreenBase < Calabash::IBase
16
16
 
17
17
  # The progress bar of the application is a custom view
18
18
  def wait_for_progress
19
- wait_for { element_does_not_exist "* marked:'#{loading_screen}'" }
19
+ wait_for(:timeout => 10) { element_does_not_exist "* marked:'#{loading_screen}'" }
20
20
  end
21
21
 
22
22
  def has_text?(text)
@@ -32,14 +32,16 @@ class IOSScreenBase < Calabash::IBase
32
32
  # Setting swipe_opt that will define the swipe 'force'
33
33
  swipe_opt = nil
34
34
  case direction
35
- when :left
35
+ when :<%= (I18n.translate "directions.left").to_sym %>
36
+ direction = :left
36
37
  swipe_opt = {:'swipe-delta' => {:horizontal=>{:dx => 280} }, :offset => { :x => 300, :y => 300 } }
37
- when :right
38
+ when :<%= (I18n.translate "directions.right").to_sym %>
39
+ direction = :right
38
40
  swipe_opt = {:'swipe-delta' => {:horizontal=>{:dx => 250} }, :offset => { :x => 50, :y => 300 } }
39
- when :up
41
+ when :<%= (I18n.translate "directions.up").to_sym %>
40
42
  direction = :down
41
43
  swipe_opt = {:'swipe-delta' => {:vertical=>{:dy => 200} }, :offset => { :x => 160, :y => 100 } }
42
- when :down
44
+ when :<%= (I18n.translate "directions.down").to_sym %>
43
45
  direction = :up
44
46
  swipe_opt = {:'swipe-delta' => {:vertical=>{:dy => 200} }, :offset => { :x => 160, :y => 400 } }
45
47
  end
@@ -101,11 +103,15 @@ class IOSScreenBase < Calabash::IBase
101
103
  end
102
104
  end
103
105
 
104
- def is_on_page? page_text
106
+ # Negation indicates that we want a page that doesn't has the message passed as parameter
107
+ def is_on_page?(page_text, negation = '')
105
108
  begin
106
- wait_for(:timeout => 5) { has_text? page_text }
109
+ wait_for(timeout: 5) { has_text? page_text }
110
+ # If negation is not nil, we should raise an error if this message was found on the view
111
+ raise "Unexpected Page. The page should not have: '${page_text}'" unless negation == ""
107
112
  rescue
108
- raise "Unexpected Page. Expected was: '#{page_text}'"
113
+ # only raise exception if negation is nil, otherwise this is the expected behaviour
114
+ raise "Unexpected Page. Expected was: '#{page_text}'" if negation == ""
109
115
  end
110
116
  end
111
117
 
@@ -114,8 +120,23 @@ class IOSScreenBase < Calabash::IBase
114
120
  query = "* marked:'#{element}'"
115
121
  end
116
122
 
123
+ begin
124
+ wait_for(:timeout => 5) { element_exists query }
125
+ rescue
126
+ # Just a better exception message
127
+ raise "Element '#{element}' not found on view!"
128
+ end
129
+
117
130
  touch query
118
- sleep(1)
131
+ # Waits up to 20 seconds for the keyboard to show up
132
+ begin
133
+ wait_for(:timeout => 10) { element_exists("view:'UIKeyboardAutomatic'") }
134
+ rescue
135
+ # If the keyboard didn't show up, tries another time before rainsing the error message
136
+ touch query
137
+ wait_for(:timeout => 5) { element_exists("view:'UIKeyboardAutomatic'") }
138
+ end
139
+
119
140
  keyboard_enter_text text
120
141
  done
121
142
  end
@@ -134,4 +155,25 @@ class IOSScreenBase < Calabash::IBase
134
155
  touch("* marked:'#{id}' index:#{index}")
135
156
  end
136
157
 
137
- end
158
+ def clear_text_field field
159
+ clear_text("textField marked:'#{field}'")
160
+ end
161
+
162
+ def select_date_on_date_picker date, date_picker_field_id
163
+ # Touch the date picker element
164
+ touch_screen_element date_picker_field_id
165
+ # Waiting for the date picker to show up
166
+ wait_for(timeout: 5) { element_exists("view:'UIDatePicker'") }
167
+
168
+ # If date is today, then we have nothing to do
169
+ if date.year != DateTime.now.year || date.month != DateTime.now.month || date.day != DateTime.now.day
170
+ # Selecting 'date' on the date picker
171
+ picker_set_date_time date
172
+ end
173
+
174
+ # Touch the OK button
175
+ touch_screen_element 'Ok'
176
+
177
+ end
178
+
179
+ end
@@ -1,7 +1,7 @@
1
1
  class <%= config[:name] %>Screen < <%= config[:platform] %>ScreenBase
2
2
 
3
3
  # <%= I18n.translate 'comments.trait' %>
4
- #trait(:trait) { "* marked:'#{layout_name}'" }
4
+ #trait(:trait) { "* <%= (config[:platform] == 'Android') ? 'id' : 'marked' %>:'#{layout_name}'" }
5
5
 
6
6
  # <%= I18n.translate 'comments.elements' %>
7
7
  #element(:layout_name) {'insert_layout_identificator'}
@@ -9,7 +9,7 @@ class <%= config[:name] %>Screen < <%= config[:platform] %>ScreenBase
9
9
 
10
10
  # <%= I18n.translate 'comments.actions' %>
11
11
  # action(:touch_button) {
12
- # touch("* marked:'#{button}'")
12
+ # touch("* <%= (config[:platform] == 'Android') ? 'id' : 'marked' %>:'#{button}'")
13
13
  # }
14
14
 
15
15
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cs-bdd
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Oscar Tanner
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-11-25 00:00:00.000000000 Z
11
+ date: 2015-01-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -17,7 +17,7 @@ dependencies:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.7'
20
- type: :development
20
+ type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
@@ -31,7 +31,7 @@ dependencies:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '10.0'
34
- type: :development
34
+ type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
@@ -45,7 +45,7 @@ dependencies:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
47
  version: 0.19.1
48
- type: :development
48
+ type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
@@ -59,7 +59,7 @@ dependencies:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
61
  version: 0.6.11
62
- type: :development
62
+ type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
@@ -73,7 +73,7 @@ dependencies:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
75
  version: 2.12.2
76
- type: :development
76
+ type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
@@ -104,24 +104,31 @@ files:
104
104
  - lib/skeleton/.gitignore
105
105
  - lib/skeleton/README.md
106
106
  - lib/skeleton/config/cucumber.yml
107
+ - lib/skeleton/config/email/template.html
107
108
  - lib/skeleton/config/scripts/android/run_tests_all_devices.sh
109
+ - lib/skeleton/config/scripts/android/start_emulators.sh
110
+ - lib/skeleton/config/scripts/android/stop_emulators.sh
111
+ - lib/skeleton/config/scripts/break_build_if_failed.sh
112
+ - lib/skeleton/config/scripts/check_if_tests_failed.sh
108
113
  - lib/skeleton/config/scripts/ios/build_app.sh
109
- - lib/skeleton/config/scripts/ios/devices
114
+ - lib/skeleton/config/scripts/ios/devices.txt
110
115
  - lib/skeleton/config/scripts/ios/run_tests_all_devices.sh
111
- - lib/skeleton/features/android/android_screen_base.rb
112
116
  - lib/skeleton/features/android/features/.gitkeep
117
+ - lib/skeleton/features/android/screens/.gitkeep
113
118
  - lib/skeleton/features/android/step_definitions/.gitkeep
114
119
  - lib/skeleton/features/android/support/app_installation_hooks.rb
115
120
  - lib/skeleton/features/android/support/app_life_cycle_hooks.rb
116
121
  - lib/skeleton/features/android/support/hooks.rb
117
122
  - lib/skeleton/features/ios/features/.gitkeep
118
- - lib/skeleton/features/ios/ios_screen_base.rb
123
+ - lib/skeleton/features/ios/screens/.gitkeep
119
124
  - lib/skeleton/features/ios/step_definitions/.gitkeep
120
125
  - lib/skeleton/features/ios/support/01_launch.rb
121
126
  - lib/skeleton/features/ios/support/02_pre_stop_hooks.rb
122
127
  - lib/skeleton/features/support/env.rb
128
+ - lib/templates/android_screen_base.tt
123
129
  - lib/templates/base_steps.tt
124
130
  - lib/templates/feature.tt
131
+ - lib/templates/ios_screen_base.tt
125
132
  - lib/templates/screen.tt
126
133
  - lib/templates/steps.tt
127
134
  homepage: https://github.com/CSOscarTanner/cs-bdd
@@ -144,7 +151,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
144
151
  version: '0'
145
152
  requirements: []
146
153
  rubyforge_project:
147
- rubygems_version: 2.4.2
154
+ rubygems_version: 2.4.3
148
155
  signing_key:
149
156
  specification_version: 4
150
157
  summary: Generates an android and iOS calabash project.
@@ -1,4 +0,0 @@
1
- # <DEVICE_TARGET (UUID)> | <DEVICE_ENDPOINT (IP)> | <DEVICE_NAME>
2
- 000...000 | http://0.0.0.0:37265 | Device0
3
- 111...111 | http://1.1.1.1:37265 | Device1
4
- # EOF - Never erase this comment or the script will have problems to read this file