page-object 0.5.4 released

*** You are calling a method named table.
*** This method does not exist in page-object so it is being passed to the driver.
*** This feature will be removed in the near future.
*** Please change your code to call the correct page-object method.
*** If you are using functionality that does not exist in page-object please request it be added.

You might see a warning similar to this one when you use the new page-object release. I am planning on removing something that current exists in the gem. This post will explain what and why.

Continue reading

Default Data Revisited

I just released a new version of the page-object gem today and it contains a nice new feature. This new feature will make it very easy to apply a set of data to a screen and have it populate all of the fields. This feature, when combined with a new gem I plan to announce soon, will allow for dynamic default data that can be used to drive a web application. This data can be managed within the pages or externally.

This post is an actual section from chapter 5 of my book. It introduces the concept of Default Data and also shows how to use this new feature.

Continue reading

Running your Cukes in Jenkins

One question that I am often asked is “How do you run your cucumber scripts?”. This question usually leads to a discussion about what process and software I use to run my features in a regression-like fashion in a team setting. The questioners are usually not interested in how a developer might use autotest (my local tool of choice) to run the cuke/spec loop. They’re not interested in how a developer might run a feature on their local machine to verify they have completed a card. They’re also not interested in how a developer or tester might run the entire suite of features to verify everything still works. They want to know how to schedule the execution of the entire suite of features.

The truth is that I don’t run them. Instead I have a server process run the features for me. I am a strong advocate of having the continuous integration server run the acceptance tests continuously. This post will explain how I do it and hopefully provide you the information you need to do it as well.

Continue reading

Those pesky frames and iframes

Wouldn’t it be sweet if all of the web pages in the world were nicely formed with easy to identify elements. If you work in an environment like this, I am envious. I often find myself working with a team where the sites are not pristine (I’m being nice here).

One thing I have found difficult to work with is pages that have frames and iframes. It gets worse when the elements you are trying to work with are nested within multiple frames/iframes. To address this complexity I decided to add simple frames handling to page-object.

Continue reading

Introducing page-object gem

page-object is a simple ruby gem that assists in creating flexible page objects for testing browser based applications. To understand the inspiration for this gem please read this blog post.

This post will walk you through some of the core features of the gem. Most of the materials in this post are also on the project wiki. Please refer to the wiki for updated documentation.

Continue reading

My Book

For the past two of years I have had a string of successes and a lot of fun helping teams adopt Acceptance Test Driven Development with Cucumber. I was never brought in to do this specifically. You see, I am an agile coach and I help team adopt agile and lean practices. And yet due to these successes with Cucumber I started thinking about how I might share these experiences.

I initially decided I would write a blog series. When I outlined it I quickly determined it would take nearly thirty entries to share all I wanted to share. That was when I came up with the crazy idea of writing a book. I had no idea what I was getting myself into. For the past several months I have spent a fair amount of my free time (do I really have free time?) working on this book. With this post I am releasing the first two chapters of that book.

Continue reading

Drag-and-Drop in Watir

A month ago I was working with a team that had a need to write acceptance tests for a feature that included drag-and-drop. My initial search turned up some code that implemented it well. I have since tried to find that code again with no success so I am sorry for not being able to give credit where it is due. Anyway, I enhanced the code I originally found and wish to present it here.

Continue reading