Alex | 30 Mar 13:31 2015
Picon

[Cucumber] Can somebody give me a Hello World tutorial for Windows?

I am 2 hours and TBH it is the worst experience in months. Cukes team should learn from MS how to do tutorials. 

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Enrique Matta | 30 Mar 20:48 2015
Picon

[Cucumber] Scenario Name and cucumber.yml

Is there a way to grab the scenario name in cucumber.yml? Currently I have GUIDs but it would be nicer to grab the real scenario name for parallel_cucumber:

---
<%
ENV['TAGS'] ||= 'all'
env_id = SecureRandom.uuid
grid_opts = "-r features --guess --format progress --profile grid_html_report --profile grid_junit_report --profile grid_json_report --profile skip --profile grid_rerun --profile #{ENV['TAGS']}"
%>
# Our normal process
default: -r features --profile html_report --profile skip --profile rerun
html_report: --format progress --format html --out=report/html/report.html
rerun: -f rerun --out rerun.txt
# This is for our GRID
parallel: <%= grid_opts %>
grid_html_report: --format html --out=report/html/<%= env_id %>.html
grid_json_report: --format json --out=report/json/<%= env_id %>.json
grid_junit_report: --format junit --out=report/xml
grid_rerun: -f rerun --out rerun_<%= env_id %>.txt
# System Specific tags
all: --tags <at> regression
skip: --tags ~ <at> todo --tags ~ <at> wip
wip: --tags <at> wip --format html --out=report/wip.html

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Jeff Nyman | 30 Mar 15:09 2015
Picon

[Cucumber] [GHERKIN] Fashioning a Business Rule from a Test

Notice the title of this post is an inversion of what many would consider "proper" use of tools like Cucumber and Gherkin. I'm not disagreeing with that. What I'm showcasing here is some realities that I very often encounter. I'm hoping to get some thoughts and/or experiences.

Recently a production bug came up and the testers were tasked with creating a functional test to make sure that did not happen again. All such tests are initially framed as Gherkin-style tests, just to get people into the flow. What they came up with is this:

Scenario: Linked Child Stories Should Display in Release Tracker
Given the following HelpDesk ticket:
  | 170000 |
and the following JIRA tickets:
  | 5000 |
  | 10150 |
  | 10160 | # a child of 10150
When the HelpDesk ticket is viewed in Release Tracker
Then all JIRA tickets show up as associated with the HelpDesk ticket

The specific numbers provided here was based on specific test data that was created to replicate the condition.

The test stemmed from a bug that was found wherein JIRA tickets were (correctly) showing up as associated with a HelpDesk ticket -- but children tickets of those JIRA tickets were NOT showing up as associated with the HelpDesk ticket. The business requirement was that they should. People initially liked the above because it made it manifestly clear what was being tested. Notice, however, that it required a comment. Plus it required a bunch of incidentals, such as specific ticket numbers.

I'm curious to see how Gherkin folks here would refactor the above into something less reliant on test data and more on the business condition, while not being cumbersome to read. The easy way to state the rule is:

    "Any JIRA tickets, including sub-tasks of those tickets, should show up as individual items under the HelpDesk ticket in Release Tracker."

That, in fact, is how the business wants to word it. They are not sold on Gherkin because they feel it adds too many complicating elements to expression. The testers, on the other hand, feel that abstracting away the details is in fact what leads to exactly the kinds of bug that were found in production. What they initially came up with is:

Scenario: Linked Child Stories Should Display in Release Tracker

Given a HelpDesk ticket that has three associated JIRA tickets, one of which is a sub-task
When the HelpDesk ticket is viewed in Release Tracker
Then all JIRA tickets show up as associated with the HelpDesk ticket

Business hates that because they think their single quoted statement says *exactly* that but without all the "boilerplate" of Gherkin. Testers hate it because they feel it removes the visibility of the very thing that matters: specific test data, which also tells someone why that particular test data is being used. Developers were less concerned but in general were siding with the non-Gherkin single-line statement of the business folks.

So what business wants (and feels should be enough) -- the single quoted statement above -- and what testers and developers want (and feel must in place) -- the Gherkin structure shown above -- is often the dilemma I find myself in.

I'm immensely curious as to thoughts on the above. How would you write the above Gherkin?

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
DK | 26 Mar 13:54 2015
Picon

[Cucumber] Background that repeats

I have a Background where I have to create a number of Users. 
I'd like something similar to a Scenario Outline but for a Background.

I want something like below:

Background: Setup Users

     
Given I create Users:
       
"""
          {
              "
name": <username>,
              "
address": <address>
          }
        """



     
Examples:
         
| username | address |
         
| Tom      | NY      |

Note I don't want to pass a DataTable to the Step. I'd prefer to keep it as JSON text with substitions for each user.

Is something like this possible.

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Lorenz Leutgeb | 25 Mar 11:29 2015
Picon

[Cucumber] Status of Gherkin Editor

Dear *,

I'd be interested in using "Gherkin Editor" [1]. The last (publicly visible) activity on the code base
was about four years ago which raises the question whether the project is discontinued or what
state it generally is in.

Please help me clarify that, so I can decide to proceed.

Regards,
Lorenz

1: https://github.com/cucumber/gherkin-editor

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Wayne Sinclair | 25 Mar 05:48 2015
Picon

[Cucumber] Message "Format options is deprecated

I get the following message when running a feature file: "WARNING: Cucumber-JVM's --format option is deprecated. Please use --plugin instead.", using Eclipse with Maven

How can I resolve this?

Cucumber-java version:  1.2.2
Java version: Version 8 build 31
Eclipse version: Luna Service Release 1a (4.4.1)


--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Tristan McCarthy | 24 Mar 14:15 2015

[Cucumber] [Cucumber-JVM] Running your tests in parallel

Hi folks,

For some time now I've been running my cucumber acceptance tests in parallel using an approach that I came up with and shared a couple of years ago.
It's documented on this blog post here if you want more detail, but in summary it involves creating multiple junit runner classes, each of which relates to a tag or set of tags on a feature file. Combining this with Junit's parallel thread count settings allows me to speed up my test runs significantly.

However, this approach comes at the cost of  a large number of junit classes, which eventually (on large test suites) clutter up the code base. It's also a bit of a pain to run subsets of tests (it can be done with yet another runner class and another feature file tag) for debugging. I'm going to revisit this approach in the hope that I can come up with something a little cleaner this time around, and was wondering if anyone has successfully tackled this problem in a different way.

Does anyone have any bright ideas or sample code that offer an alternative approach? How do people solve the problem of slow test runs (especially when hooking Cucumber up to WebDriver) without addressing this?

Cheers,
Tris


--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
aslak hellesoy | 23 Mar 18:01 2015
Picon

[Cucumber] Help us improve the info architecture on cukes.info

We're in the process of adding lots of content to cukes.info.

Content needs to be organised so it makes sense to website visitors, and you can help us with that!
Just head over to https://cukes.info and fill in the survey.

Or go directly to http://ows.io/os/nj760xno

Thanks!

Aslak

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
Matthew Linares | 19 Mar 22:13 2015
Picon

[Cucumber] [JS] tests pass without functionality existing

I have started building a test suite for a Meteor app with Meteor-Cucumber-JS  (following http://joshowens.me/cucumber-js-and-meteor-the-why-and-how-of-it/). But some tests are passing without any functionality in place.

For example, the test file login.feature includes

 Feature: Allow users to login, with Scenario: A user can login with valid information and When I click on sign in link

which is supported in the file loginSteps.js with:

this.When(/^I click on sign in link$/, function (callback) { helper.world.browser. waitForExist('.at-signup', 7000). waitForVisible('.at-signup'). click('.at-signup'). call(callback); });

The sign in button actually has 

class="btn btn-default navbar-btn"

...console reads:

? (STDERR) Unable to find element with css selector '.at-signup'.

...and yet Velocity says that the test passes in 858ms.


Another test passes url(helper.world.cucumber.mirror.rootUrl + "event/1") although there is no such url.

Other tests do fail, however, like:

getText('.user-menu .dropdown-top-level', function (err, username) { assert.equal(username[0], 'userme'); }).

with error:

Then I should be logged in Fail TypeError: Cannot read property '0' of undefined

Any ideas? Thanks!

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
FS | 20 Mar 16:37 2015
Picon

[Cucumber] [Cucumber-JUnit][Cucumber-JVM] json results empty <at> AfterClass

Hi,

I am using the json results generated by cucumber and converting them into html reports using a method GenerateReports.generateReports(). The issue is that the json file is empty when <at> AfterClass runs. When is the json file populated with results?


<at> RunWith(Cucumber.class) <at> CucumberOptions(features = { "classpath:features/" }, format = { "json:target/JsonResults/cucumber.json" }, dryRun = false) public class CucumberTestsRun { <at> BeforeClass public static void setup() { System.out.println("Ran before"); } <at> AfterClass public static void teardown() throws Exception { System.out.println("Ran after"); GenerateReports.generateReports(); }
Regards,
FS

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.
FS | 23 Mar 15:12 2015
Picon

[Cucumber] [Cucumber-JVM] json results empty <at> AfterClass

Hi,

I am using the json results generated by cucumber and converting them into html reports using a method GenerateReports.generateReports(). The issue is that the json file is empty when <at> AfterClass runs. When is the json file populated with results?

<at> RunWith(Cucumber.class) <at> CucumberOptions(features = { "classpath:features/" }, format = { "json:target/JsonResults/cucumber.json" }, dryRun = false)public class CucumberTestsRun {  <at> BeforeClasspublic static void setup() {    System.out.println("Ran before");}  <at> AfterClasspublic static void teardown() throws Exception {    System.out.println("Ran after");    GenerateReports.generateReports();}


Regards,
FS

--
Posting rules: http://cukes.info/posting-rules.html
---
You received this message because you are subscribed to the Google Groups "Cukes" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cukes+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
For more options, visit https://groups.google.com/d/optout.

Gmane