From Microformats Wiki
Revision as of 01:22, 6 July 2007 by RgyDd4 (talk | contribs)
Jump to navigation Jump to search

Requirements Testing Examples

The XUnit framework approach to writing test cases is still the most common way of implementing automated tests, but there are already a number of examples of mini languages and formats for web testing:

Feed Parser Test Suite

The XML files from the Feed Parser Test Suite created by Mark Pilgrim are prefixed with a comment containing a description and expectation, decoupling the test assertions from imperative code:

Description: Atom namespace (official)
Expect:      bozo and feed['title'] == u'Example Atom'

Description: entry contributor homepage
Expect:      bozo and entries[0]['contributors'][0]['url'] == u''

Canoo WebTest

Canoo WebTest runs test steps defined in the Ant XML format:

 <target name="login" > 
  <webtest name="normal" >