Automated Test Runner

Hi,

I thought this would be worth sharing. I put up a sketch of what an  
automated test runner could be like here:

http://tc.labs.opera.com/apis/EventSource/testrunner.htm
http://tc.labs.opera.com/apis/XMLHttpRequest/testrunner.htm

(Now these are not (well, no longer) part of HTML5, but they use the  
infrastructure we agreed to use for HTML5 so they work for illustrating  
the concept, I think.)

All it requires is tests to be written using testharness.js as well as  
linking to testharnessreport.js. See the individual files for details.  
testharnessreport.js can be very simple:

http://tc.labs.opera.com/resources/testharnessreport.js

The problem with this test runner is that the amount of tests are not  
known upfront. We only know the amount of files. So if we make a test file  
manifest it will have to include data on how many tests are in a given  
file to give accurate reporting. The reporting itself could be improved as  
well.

Cheers,


-- 
Anne van Kesteren
http://annevankesteren.nl/

Received on Monday, 15 November 2010 12:38:26 UTC