ci_reporter output for Watir

I’ve been using the ci_reporter gem to grab the results from my Test::Unit verifications and put them in an xml file.  Then I apply an xsl stylesheet to the xml to transform the results into html.  It’s not the prettiest report, but it beats reading xml or parsing through command line output.  My goal is to move my test framework to a rails app for better reporting and data management, but for now, I’m sticking with the ci_reporter output.  Here’s how it works:

First you need to install the ci_reporter gem and require the ci_reporter rake task in your framework class (in my case in my Test::Unit class):

require 'ci/reporter/rake/test_unit_loader'

After running your framework, ci_reporter will create ‘test/reports’ subdirectories and place the xml output of your tests in the reports folder.

Next, you’ll need to transform this xml output to html.  This is accomplished by applying an xsl stylesheet to your xml.  I’ve saved my stylesheet text as a doc file here:

To apply the stylesheet, add the following at line 2 of your xml output:

<?xml-stylesheet type="text/xsl" href="transform-results.xsl"?>

In my case, I just make sure the stylesheet is saved in the local directory.  If you want to save it somewhere else, you’ll need to supply a relative path.

As part of my framework, I’ve automated updating the xml output and renaming  it with a test run.  Then it saves the xml output and xsl transform to a network location to share with the rest of the team.

This assumes that IE is your browser of choice, to view the report in Firefox, add the following line to your xml output at line 3.

<xsl:if test="system-property('xsl:vendor')='Transformiix'"></xsl:if>

July 23, 2009 at 9:09 pm Leave a comment

Watir Podcast #23 – turning the table on Zeljko

I recently had the pleasure of recording a Watir Podcast with Watir Core Team member Zeljko Filipin.  You can find it at Zeljko (aka Z*) is very involved with the Watir community and has been recording Watir podcasts for a year now.

April 14, 2009 at 9:04 pm Leave a comment

watir-console, my new best friend

I’ve made the move from irb to watir-console for troubleshooting Watir code.

Since version 1.5.2, watir-console has been part of the Watir installation.  Basically, it’s an irb session on steroids.  It’s launched through a regular console the same way irb is (c:\>watir-console), but it also includes the following:

  • a local log of your session (saved as console.log)
  • tab complete functionality
  • does require ‘watir’ automatically

Jim Knowlton has a great example of adding helper class functionality to watir-console so that any classes or methods you want can be automatically available when you launch watir-console.

Pair watir-console with an HTML element inspector like Firebug (for Firefox) or IE Developer Toolbar, and you have a great environment for testing and troubleshooting watir tests.

April 2, 2009 at 7:06 pm Leave a comment

Our coolest project ever

A few years ago, my husband traded a 40’s-era Chrysler hubcap that he had hanging in our garage for an old Pepsi machine.  The guy he traded had an old Chrysler and had been looking high and low for the one hub cap he was missing.  Plus, he had stocked the soda machine with beer and was tired of his son’s college-age friends’ raiding it.  We felt guilty, but he considered it a fair trade.

The soda machine languished in a corner of our garage until our beer fridge died last summer.  We pulled it out of the corner, crossed our fingers and plugged it in – it fired up like new!  It needed a paint job, so John painted the body and my Mom painted the new logo.  I wired it to bypass the broken coin mechanism and voila! – we have the most excellent soda beer machine I’ve ever seen.

Props to Mom and John for the paint job!

Props to Mom and John for the paint!

March 26, 2009 at 11:17 pm Leave a comment


There’s a certification that project management professionals can get from the aptly-named Project Management Institute.  It’s one of the more popular certifications, and as I understand, it’s not easy.  To be certified, you have to go to a lot of classes, work as a PM professional and keep the certification up-to-date.

The worst PMs I’ve worked with have been PMI-certified.  There.  I said it.  I said it, and here’s why…..

I don’t believe that the PMI is teaching bad techniques – I’m sure they’re very valuable.  However, these techniques should not be applied as cookie-cutters at the expense of common-sense and an awareness of the project at hand.  They shouldn’t be thrown up as hurdles for the sake of clearing them so that the PM can mark something off a checklist they got from a class.  Some people understand this and use what they learned at PMI as it makes sense.  Others don’t and try to shoehorn a project into their view of what every project should be.

I’m not saying that everyone with PMI certification should be avoided.  On the contrary, I’ve worked with great PMs who have PMI certification.  However, all of the worst PMs I’ve worked with have it and some of the very best have no certifications at all.  The best PMs understand that most of what they do is probably transparent to the rest of the group – things go smoothly because they’re clearing the road.

For me, a PMI certification in a signature line is a flag that this person could be trouble.  Often, I’m happily surprised when they turn out to be great.  It’s like any other certification – not a substitute for good experience and natural ability.

(I’ll leave software test certifications for a whole other rant.)

March 22, 2009 at 11:11 am Leave a comment

Multiline comments in Ruby.

Maybe the Google failed me, maybe I was just not being observant, but when I first started using Ruby, I could not for the life of me figure out how to make multiline comments.  I had resorted to using lots of # signs, which isn’t especially difficult, but it just felt like there had to be an easier way.

Turns out, there is an easier, although perhaps still a bit clunky, way.  To start a multiline comment put =begin before the first line of comments and =end after the last line.  Note that these commands can not be indented at all, you have to put them at the beginning of the line.

March 17, 2009 at 1:33 am 3 comments

How not to impress your boss.

A couple of years ago, I was the new QA Manager for a small start-up.  There was a mountain of work to do (a complicated app and SMTP protocol to learn, test plans to write and about 50 defects to verify), I was in the process of building a team, I was short on equipment,  the CTO resented the fact that they needed a QA team at all and he hated me from day one.  In short, it sucked to be me and I was super stressed out.

We were crammed into a tiny suite, but a big new space in the same building was being renovated for us to move into.  I mentioned to my boss that I was having a hard time making progress on my to-do list because I was constantly being interrupted.  He said that his office in the new space was finished and I should hide out there until he moved in.  I immediately took him up on the offer and started rounding up my stuff.

In my desk was a bottle of wine I’d received as a birthday gift, but had forgotten to take home.  It was after 5:00 and I knew I was in for the long haul that night, so I decided that a glass or two of wine was warranted.  The only problem was that I didn’t have a corkscrew and couldn’t find one anywhere in the office (strange, because we had happy hours pretty often).

No bottle was going to outsmart me – I wasn’t about to let a silly thing like the lack of the proper tool keep me from enjoying a good Shiraz.  I found an allen wrench on a mostly-assembled IKEA desk and decided that I would just push the cork into the bottle rather than pulling it out.  Genius!

I gently started pushing down on the cork and felt it start to give.  Yippee!  Progress!  Suddenly, the cork gave way entirely and with a whoosh, my bottle of wine was transformed into a fountain.  Everything in a 10-foot radius was splattered with wine drops.  The brand new wooden desk, the freshly-painted walls, the newly-cleaned carpet, my laptop, my notebook, a big stack of documentation, me – all covered with red, red wine.

I didn’t realize I wasn’t the only one there and before I could even catch my breath, the IT Manager poked his head in the office.

“Are you OK?” he asked, stifling a chuckle.

“Uh…nope…not really.” I said as wine dripped off my nose.  “Does this look as bad as I think it does?”

“Yeah – it doesn’t look good.  I’ll help you clean up.”

What a great guy!  He helped me find spot cleaner for the carpet and we took to dabbing up wine from every surface.  After I thanked him, I IM-ed my boss to admit I’d nearly ruined his brand new office.  He laughed, and surprisingly, didn’t kick me out.  There was even some wine left in the bottle.

A couple of weeks later, everyone moved into the new space.  After my boss moved into his office, he marveled that there was no sign of my wine-bombing.  I wanted to take credit for a great clean-up, but all I could do was point to the ceiling.  Even the ceiling tiles had been showered, but we couldn’t get the wine off them.

Not the best mark I’ve made on a company, but it could turn out to be the most lasting…..

March 13, 2009 at 3:51 pm Leave a comment

Older Posts


Recent Tweets

Error: Twitter did not respond. Please wait a few minutes and refresh this page.