You need to be added to the ContributorsGroup to edit the wiki. But don't worry! Just email any Mailing List, grab us on IRC, or submit a ticket to JIRA if you want to be added.

Summary

This page focuses on how to create a test case for couchdb and run it. Creating failing test cases to identify a problem is a great way to contribute to couchdb.

Context

To run the existing tests

When a test is failing

To create a new test

Steps to run your test

Example

I added these lines to the 'lots_of_docs' method, to make the test fail:

     // Check _all_docs with descending=true again (now that there are many docs)
     var desc = db.allDocs({descending:true});
     T(desc.total_rows == desc.rows.length);

Then I attached the diff to an existing Jira bug that described the issue.

How_to_create_tests (last edited 2011-11-23 15:13:11 by JanLehnardt)