Testing output of same data across multiple formats

21 views
Skip to first unread message

Bob Farrell

unread,
Jan 25, 2012, 11:47:46 AM1/25/12
to cu...@googlegroups.com
Hi there,

We generate a report for some data as HTML that allows the user to scroll through it and look at various facts and figures associated with a record. The user can then choose to download the report as an Excel file. The structure/layout of both the HTML and the .xls are the same. In this instance we'll be looking at the XML before we convert to .xls for our testing.

Our problem is that we have a scenario for a required feature of the report (which uses a DSL we wrote to navigate the webpage and inspect the resulting output) but this scenario would be the same for both HTML and .xls output. At least the "When" and "Then" steps would be exactly the same. We could write another DSL and switch between the two based on some environment variable being set, but then other tests would fail for the HTML output if we are testing just the .xls ...

So we're wondering if there is some popular idiom to solve this problem ? Testing that the same data is being output into multiple formats within the same scenario.

Let me know if I can clarify any further and thanks in advance for any help.

Matt Wynne

unread,
Jan 26, 2012, 4:07:31 AM1/26/12
to cu...@googlegroups.com
There are a couple of ways to tackle this. The simplest is to use a Scenario Outline. Do you know about those?

cheers,
Matt

Freelance programmer & coach

Reply all
Reply to author
Forward
0 new messages