Erik A. Hanson's Weblog

Archive for May, 2007

A Ruby Script To Generate a JsUnit Suite

Posted: Saturday, May 26th, 2007    Tags: Howto, Javascript, JsUnit

I’ve got a bunch of JsUnit tests for a project I’m working on and I wanted an easy way to create a JsUnit suite that can run all the tests but also run any individual test page. Also, I wanted to be able to view any test page so I could debug the tests with Firebug. I also didn’t want to run a web server all the time, so I wanted a script that would create a static HTML file.

Element.stylize via Prototype.js

Posted: Friday, May 25th, 2007    Tags: Javascript, Web development

I often want to add a bunch of styles to an element, so I wrote a simple stylize method.