Wednesday, October 23, 2013

Cucumber Word salad

Great attendance & surprises indeed last night at the GeekBookClub, more properly called the LAJUG Study Group.

We began the new book: The Cucumber Book, seen above.

It's a bit Ruby-esque, but applicable to Java via the download of cucumber-jvm, which I'll need to investigate.

So, I got my MacBookProRetina loaded up with Ruby as a prerequisite for the Cucumber install, and followed the appendix without serious issue to get a working cucumber installation up to try things out. And I entered the first bits of chapter two's "First Taste," and got the same results.

Apparently, the whole Cucumber/BDD -- or Behavior Driven Development -- is based around attempting to provide a communication tool that can involve business people as well as developers in producing executable specifications.

To begin with Cucumber is a command line tool.

That's cool, to the inner Hacker that constitutes TheHackerCIO, because GUIs are for those who can't Hack. Your mileage may vary.


There is a sort of word salad of technical terms in the cucumber suite, so here is a quick glossary ...

feature is  a flat file that contains plain-text, ordinary language descriptions of one or more scenarios.

A scenario is a list of steps for Cucumber to work through. These scenarios must follow a particular syntax so that Cucumber can work through them.

Gherkin is the name for the syntactical rules required of the scenarios. Gherkin uses keywords such as Feature, Scenario, Given, When, and Then to provide the needed structure to the DSL.

The steps, or step-definitions are where Ruby programs actually get bound to the specification, thus making them executable.

The essential point of all this is to make it possible for business -- that it, non-technical -- people to get involved in writing acceptance tests. That seems like a good thing.

The big surprise in last nights discussion was in one new, first-time attendee. Newcomers are freely and warmly welcomed at our book club; at whatever level and from whatever technology background. And this newcomer was already very familiar with both Ruby and Cucumber!

So, instead of a discussion among people all eager to learn a new technology, we had an interaction with someone who already new and HATED the technology! That was a twist! This person was coming to try to see whether she could be convinced of the value of Cucumber from the Pragmatic Programmer book!

We spent quite a bit of time trying to understand what her issue was with the tool, and we all quite happily viewed a demo of how Cucumber works, which she whipped up for us on her Macbook and ran.

Seeing a live demo on the spot certainly made it a lot easier to grasp the whole essence of Cucumber. It's amazing how much superior a tutorial is to reading, no matter how much I like reading.

So, you'll have to stay tuned for future blog postings to see what we learn about Cucumber and whether it's useful or a pain! No matter what the verdict is, new technology needs to be learned about and evaluated. And so ...

I Remain, Ever Learning, and ...


No comments:

Post a Comment