Sam's Blog entries for category 'qa' Subscribe to feed for category 'qa' Released

Date: Wednesday, 14 April 2010, 17:31.

Categories: perl, ironman, text-matrix, template-benchmark, qa.

Even with twenty thousand distributions on CPAN, a figure that should truly boggle the mind, I'm still often surprised to find myself trying to do something reasonably basic that hasn't been covered already.

While writing Template::Benchmark I wanted to lay out a "feature matrix", a matrix of template engines and the features they supported: a simple grid of Y/N characters in even, regular spacing.

To my surprise none of the CPAN table modules covered this, they'd all force the layout to depend on the width of the column labels or try to force the column labels to wrap at single-character width. So I hacked together some ugly code myself and got on with writing the rest of Template::Benchmark.

As with all ugly one-off code though, you find yourself wanting to use it elsewhere and constrained by how un-resuable it is.

Well, I did what I should have done in the first place, I made it Text::Matrix - Text table layout for matrices of short regular data.

Only a beta 0.99_01 release, but should be hitting a CPAN mirror near you shortly if it isn't there already.

See below the cut for example output and more details.

As part of my development environment for Template::Sandbox, I maintain a suite of regression benchmarks, using Template::Benchmark against all previous versions of the distribution.

While a crude tool, it's something I find useful and thought I'd use this week's column to share how I automated as much pain away as I could.

Today I released a new beta of Template::Benchmark (v0.99_07) and one of the changes, along with the addition of 4 new template engine plugins (Tenjin, Template::Tiny, Text::Template::Simple and NTS::Template), is that it splits the author/release tests away from the install tests.

This was a royal PITA, so I thought I'd cover the how and why of what was done.

Browse Sam's Blog Subscribe to Sam's Blog

By year: 2010, 2011, 2012, 2013.

Or by: category or series.

© 2009-2013 Sam Graham, unless otherwise noted. All rights reserved.