Michael E. Ensminger (MEE)
Software Quality Assurance (SQA)

Using XML for Test Case Definition, Storage and Presentation

© 2006–2017 by Michael E. Ensminger. Unless otherwise noted, the content of this site is licensed under a Creative Commons Attribution NonCommercial 2.5 License.

Prepared for and presented at The 2002 Pacific Northwest Software Quality Conference on October 16, 2002.


The current interest in web services fuels the rise of XML as a popular technology. The advantages provided by XML in application development and enabling application integration apply equally to supporting the test effort. This paper provides a short overview of XML and related technologies, and an example of the application of these technologies to test management. A simple test case DTD and example XML document is developed. This XML is then transformed into an HTML page via an XSL stylesheet. These simple examples demonstrate the power of this approach and also identify some of the issues that are encountered during implementation. Building on the simple example, a more complex (and realistic) definition of test suite XML is developed using XML schema. Finally, some additional XML documents and their uses in a test management system are discussed.

Paper (pdf)
Slides (ppt)


XML / XSL Basics
Example XML Example DTD Example XSL Example Rendered XSL
Example Schema

How to Store XML
Apply Stylesheet to
XML syntax
Simple Database Schema

Simple Test Case XML / XSL
Example A XML Test Case DTD Test Case XSL Example A Rendered XSL
Example B XML Test Case Schema Example B Rendered XSL

Full Featured Test Suite XML / XSL
Example XML Test Suite Schema Test Suite XSL Example Rendered XSL

Other Uses for XML - Test Execution Results
Sample Result XML Full Detail XSL Full Detail Rendered XSL
Summary XSL Summary Rendered XSL
Bugs Entered XSL Bugs Entered Rendered XSL
Failed Test Cases XSL Failed Test Cases Rendered XSL

Other Uses for XML - SQL Transformation
Example A XML Insert SQL XSL Example A Rendered XSL
Example B XML Example B Rendered XSL
Update SQL XSL Example A Rendered XSL
Example B Rendered XSL