Docs: Update testing documentation

Update testing documentation to reflect recent changes
in https://review.gerrithub.io/#/c/396751/

Change-Id: I494242b012996c72272f980ed62862bc843ae156
This commit is contained in:
Felipe Monteiro 2018-02-13 03:17:26 +00:00 committed by Anthony Lin
parent b0c2f1c4e2
commit c6d01adc36
1 changed files with 10 additions and 6 deletions

View File

@ -45,7 +45,7 @@ variable via ``PIFPAF_URL`` which is referenced by Deckhand's unit test suite.
Overview
--------
Unit testing currently uses an in-memory sqlite database. Since Deckhand's
Unit testing currently uses an in-memory sqlite SQLite. Since Deckhand's
primary function is to serve as the back-end storage for UCP, the majority
of unit tests perform actual database operations. Mocking is used sparingly
because Deckhand is a fairly insular application that lives at the bottom
@ -53,18 +53,22 @@ of a very deep stack; Deckhand only communicates with Keystone and Barbican.
As such, validating database operations is paramount to correctly testing
Deckhand.
To run unit tests using PostgreSQL, execute::
To run unit tests using SQLite, execute::
$ tox -epy27
$ tox -epy35
against a py27- or py35-backed environment, respectively. To run individual
unit tests, run::
against a py27- or py35-backed environment, respectively.
To run unit tests using PostgreSQL, execute::
$ tox -epy27-postgresql
$ tox -epy35-postgresql
To run individual unit tests, run (for example)::
$ tox -e py27 -- deckhand.tests.unit.db.test_revisions
for example.
.. warning::
It is **not** recommended to run postgresql-backed unit tests concurrently.