How to Write a Dtest
Apache Cassandra's functional test suite, cassandra-dtest, is an open-source Python project on GitHub where much of the Apache Cassandra test automation effort takes place. It consists of end-to-end, black box tests that run against Cassandra clusters via CCM (Cassandra Cluster Manager). The process of adding a new dtest involves choosing the appropriate module and/or test suite, creating a new test method with "test" in its name, adding a docstring describing the test's purpose and how it verifies it, launching a C* cluster using CCM, connecting to the cluster using one of the methods from dtest.py, performing testing logic using Python driver or ccmlib API, asserting C*'s correctness with assertions.py and built-in assertions, ensuring code compliance with PEP8, and finally opening a pull request against the riptano/cassandra-dtest repository for review and merging.
Company
DataStax
Date published
Feb. 19, 2016
Author(s)
Philip Thompson
Word count
696
Hacker News points
None found.
Language
English