From 454e8889338c3def27e082906ddc359d43d490db Mon Sep 17 00:00:00 2001
From: Mark Goddard <mark@stackhpc.com>
Date: Thu, 6 Apr 2017 10:19:34 +0100
Subject: [PATCH] Add doc8 for documentation style checking, fix the one issue
 found

---
 doc/source/usage.rst  | 2 +-
 test-requirements.txt | 1 +
 tox.ini               | 5 ++++-
 3 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/doc/source/usage.rst b/doc/source/usage.rst
index 2442f4839..01bf40a6b 100644
--- a/doc/source/usage.rst
+++ b/doc/source/usage.rst
@@ -369,7 +369,7 @@ To deploy the overcloud services in containers::
     (kayobe-venv) $ kayobe overcloud service deploy
 
 Once this command has completed the overcloud nodes should have OpenStack
-services running in Docker containers. 
+services running in Docker containers.
 
 Interacting with the Control Plane
 ----------------------------------
diff --git a/test-requirements.txt b/test-requirements.txt
index c23375fdc..1df17db0e 100644
--- a/test-requirements.txt
+++ b/test-requirements.txt
@@ -5,5 +5,6 @@
 hacking>=0.12.0,<0.13 # Apache-2.0
 
 coverage>=4.0 # Apache-2.0
+doc8 # Apache-2.0
 sphinx>=1.5.1 # BSD
 oslotest>=1.10.0 # Apache-2.0
diff --git a/tox.ini b/tox.ini
index b64d889f2..4d3418e31 100644
--- a/tox.ini
+++ b/tox.ini
@@ -14,7 +14,10 @@ deps = -r{toxinidir}/test-requirements.txt
 commands = unit2 discover {posargs}
 
 [testenv:pep8]
-commands = flake8 {posargs}
+commands =
+  flake8 {posargs}
+  # Check the *.rst files
+  doc8 README.rst CONTRIBUTING.rst doc/source --ignore D001
 
 [testenv:venv]
 commands = {posargs}