Thursday, May 27, 2010

TestGen4Web: A million downloads and counting

Today, my TestGen4Web moved past a million download mark on our developer website. It has come a long way since the original idea of just automating your actions on the browser.

To mark the occasion, Calvin got me ten '100 Grand' chocolate bars :)

A quick word about what the tool does: TestGen4Web is essentially a recorder of your actions on the firefox browser, and can play it back (you know, like your DVR). The extension also comes with a editor where you can create loops, add conditions, parameterize data and load datasets - essentially creating a functional-test. The test can also be run on the command line using a companion tool which I call htmlunit-interpreter and run them without a browser.

The first time I thought of this was at my first job, at which, reproducing a bug would take at least 10 clicks and 5 text box entries. I realized that it really was not an effective use of time (duh!).

Those were the glory days of Internet Explorer, and I wrote a vbscript to open the browser and control the elements in it. The first version was a set of library functions to "click the 3rd link", "enter text in 5th textbox" and so on. Writing such tests was still manual.

When Firefox came out, it brought with it the concept of wrting browser plugins. I realized that these were exactly the carrier I was looking for all along. Running with the same permissions as the browser was exciting, and a similar automation use case came up prompting me to write the first version of 'testgen4web' (short for Test Generator for Web applications).

Now at version 1.1.0 (download here) with more than a million downloads over all the versions, its come a long way. Thanks to SpikeSource for providing me the platform, and thanks to users for .. well, using it.

Here is Keisuke's schematic rendering of the project summary. Published on our developer site.

Thursday, February 18, 2010

thunderbird-3 hack: fix number of addresses shown before the "more" link

If you use thunderbird 3, you may have noticed an annoying link labeled 'more' on every address category (to, cc) after just 1 address is listed.

Friday, February 12, 2010

My simple python driver for my touch screen input

The story begins when I got a laptop (netbook I should say) with a touch screen from a company named "MosArt"

A version of 64-bit windows 7 came pre-installed on it, and the touch screen worked pretty well - it had its moments, but worked.

I installed ubuntu on another partition, and expected the touch screen to work out of the box. But doesn't look like anybody has heard about the company yet (could not find any references to them by regular searches). It was time to write my own driver.

Wednesday, February 10, 2010

Simple HTML Tabs

Ever wondered how those tabs are created in html? You can create tabs very easily using html list elements

Here is a screenshot of simple html tabs

All you really need here is to create a unordered list (UL) with class attribute set to "nav" and the list element (LI) with class attribute set to "selected" for the tab you need selected.

<style>
    ul.nav { border-bottom:1px solid gray; }

    ul.nav li {
        display:inline;
        position:relative;
        padding:5px 5px 5px 5px;
        top:-5px;
        border:1px solid gray;
        background-color:lightgray;
        margin-left:5px;
    }
    ul.nav li.selected {
        background-color:white;
        border-bottom:none;
        top:-4px;
    }
</style>
<ul class="nav">
    <li class="selected">Tab 12
<li>
    <li>Tab 2<li>
    <li>Tab 3<li>
    <li>Tab 4<li>
</ul>

The above html was generated using vim - for those who are interested, vim can generate html with syntax highlighting with a simple command


:runtime! syntax/2html.vim