Pylot - Dev Update #4 - Web Performance/Load Test Tool (New Name and Defining Test Cases)
Pylot - Dev Update #4 - Web Performance/Load Test Tool (New Name and Defining Test Cases)
Submitted by Corey Goldberg on Tue, 24/07/2007 - 16:25.PyLT has been renamed to Pylot (some sort of abbreviation for "Python Load Test")
I realized that having a pronounceable name for a piece of software is pretty important :)
So...
As I develop my load test tool, I need a way to define test cases. Here is my
first attempt:
What Is A Pylot Test Case?
You must declare your test cases in an XML file. This is the format that the test engine understands. Editing XML may seem natural to some people, but awkward to others. The nice thing about this structure is that it will be very easy to create a more friendly user interface [sometime in the future] for defining test cases.
A test case is defined using the following syntax. Only the URL element is required.
<case>
<url>URL</url>
<method>HTTP METHOD</method>
<body>REQUEST BODY CONTENT</body>
<add_header>ADDITIONAL HTTP HEADER</add_header>
<verify>STRING OR REGULAR EXPRESSION</verify>
<verify_negative>STRING OR REGULAR EXPRESSION</verify_negative>
</case>
Below is an example of the simplest possible test case file. It contains a single test case which will be executed continuously during the test run. The test case contains a URL for the service under test. Since no method or body defined, it will default to sending an HTTP GET to this resource. Since no verifications are defined, it will pass/fail the test case based on the HTTP status code it receives (pass if status is < 400).
<testcases>
<case>
<url>http://www.example.com/foo</url>
</case>
</testcases>
Related:
