Gáspár Nagy on software

coach, trainer and bdd addict, creator of SpecFlow; owner of Spec Solutions

SpecFlow Tips: Collect more information on error (part 2)

by Gáspár on May 13, 2016

In the first part of this article I described why it is important to provide more information on errors and how you can collect useful artifacts (screenshots, log files, etc.) in an [AfterScenario] hook. In this part I would like to explain how to write more informative assertions.

[read more…]

SpecFlow Tips: Run only specific scenarios in TFS/VSTS build

by Gáspár on May 11, 2016

Many teams who use SpecFlow setup their continuous integration environment with Microsoft Team Foundation Server (TFS) or its cloud based service, the Visual Studio Team Services (VSTS, fka VSO). TFS/VSTS has an improved build system, where it is much easier to setup and customize builds. Regardless of the fact, which unit test provider you use for SpecFlow, it is super easy to setup a build to run your BDD scenarios, because all the major unit test frameworks provide the necessary adapter for it (this is the same adapter that you need to run the tests from the Visual Studio Test Explorer Window).

Since the infrastructure is relatively new and very generic, it is sometimes hard to find information on particular questions. For SpecFlow users one of the most typical question is, how to run only specific scenarios (marked with a tag) in a TFS/VSTS build.

[read more…]

SpecFlow Tips: Collect more information on error (part 1)

by Gáspár on April 1, 2016

When BDD scenarios are turned into executable automated tests, they usually automate the application together with its dependencies (e.g. end-to-end with browser automation or headless with controller-layer automation). This ensures that the application works as a whole, but unfortunately it also makes the analysis of a failing test harder. So many things can go wrong, especially if you run these tests on a build server, where the monitoring of the different actions is limited. Because of this, providing more information on the context where the error has happened (screenshot, log, last transaction, etc.) is really helpful. In this post I show you how this can be done.

[read more…]

BDD Addict Newsletter March 2016

by Gáspár on March 7, 2016

Dear BDD Addicts,

bddaddict-newsletter Welcome to the second BDD Addict newsletter. My plan is to collect interesting posts, articles and events about behavior driven development, SpecFlow, Cucumber moreover also test automation and agile testing. I’m following many channels, but surely not all. So if you have seen something that fed your addiction, just send me the link with a few comments to bddaddict@specsolutions.eu.

How do you know that you are already a BDD addict? I don’t know, but google assistant recently started to advertise me the rates for DB Base Metals Double Long (currently at $4.52)… do you also have that? Yeah, this is BDD at The New York Stock Exchange (Arca)…

So while waiting for BDD to prosper, your dose for March 2016 contains the following topics:

  • [Watch] TDD – Eat it raw! (Kevlin Henney)
  • [Background] Why Cucumber? (Aslak Hellesøy)
  • [Learn:SpecFlow] How to structure test automation code with the driver pattern (David Leitner)
  • [Learn:SpecFlow] Feature file backgrounds (Gaspar Nagy)
  • [Process] Given/When/Then — How to phrase them? (Liz Keogh)
  • [Process] Climbing up and down inside the Test Pyramid (Konstantin Kudryashov, Mathias Verraes)
  • [Event] Agilia Conference 2016

Read the full newsletter…

BDD Addict Newsletter March 2016

Subscribe to it at http://specsolutions.eu/bddaddict so that you never miss it! (Did you get the February issue?)