views:

44

answers:

1

I am using YUI to test my JavaScript app, and want to integrate the test results into my CruiseControl build system. How can I use CruiseControl to run the tests? I initially thought about using the JUnit plugin to drive the tests, but that is a no go.

Does anyone else have this working?

(Please note: Changing either YUI or CruiseControl isn't an option for me.)

+1  A: 

We have YUI Tests integrated with Hudson for our CI builds. The process should be pretty identical for CC, since we kick off the testing through a Java task in ANT.

We have a selenium driver (a java impl - we're working on making it public) which talks to a SeleniumRC instance, pointing it to the HTML files in build workspace to run tests.

You could take a stab at writing your own selenium driver: http://seleniumhq.org/docs/05_selenium_rc.html#learning-the-api

The driver code talks to a SeleniumRC instance, and asks it kick off a browser pointing to the YUI Test based HTML test files from the build.

The HTML files run YUI Test Runner on load, and the driver injects code on page load, to pick up test results from YUI Test Runner when it's done running, and store them as files for Hudson to parse.

Regards, Satyen

YUI Team

Satyen Desai