Test documentation under Tox

This commit is contained in:
Luke Murphy 2019-08-04 18:54:27 +02:00
parent af2c80c3e2
commit 772eeb8da3
No known key found for this signature in database
GPG key ID: 5E2EF5A63E3718CC
6 changed files with 16 additions and 3 deletions

3
.gitignore vendored
View file

@ -1,5 +1,8 @@
*.py[co] *.py[co]
# Documentation
doc/_build/
# Packages # Packages
*.egg *.egg
*.egg-info *.egg-info

View file

@ -6,6 +6,8 @@ matrix:
env: TOXENV=py27 env: TOXENV=py27
- python: 2.7 - python: 2.7
env: TOXENV=lint env: TOXENV=lint
- python: 2.7
env: TOXENV=docs
install: install:
- pip install tox - pip install tox

0
doc/_static/.git-dont-delete-me vendored Normal file
View file

View file

@ -15,7 +15,7 @@ Getting access to LDAP in a command
=================================== ===================================
To get access to LDAP you need to authenticate against it, for that you need to To get access to LDAP you need to authenticate against it, for that you need to
declare your command with requiring authentication in the :ref:`actionsmap` this way: declare your command with requiring authentication in the actionsmap this way:
:: ::

View file

@ -46,7 +46,7 @@ def call_async_output(args, callback, **kwargs):
Keyword arguments: Keyword arguments:
- args -- String or sequence of program arguments - args -- String or sequence of program arguments
- callback -- Method or object to call with output as argument - callback -- Method or object to call with output as argument
- **kwargs -- Additional arguments for the Popen constructor - kwargs -- Additional arguments for the Popen constructor
Returns: Returns:
Exit status of the command Exit status of the command
@ -167,7 +167,7 @@ def run_commands(cmds, callback=None, separate_stderr=False, shell=True,
callback is given, a "subprocess.CalledProcessError" callback is given, a "subprocess.CalledProcessError"
will be raised in case of command failure. will be raised in case of command failure.
- separate_stderr -- True to return command output as a 2-tuple - separate_stderr -- True to return command output as a 2-tuple
- **kwargs -- Additional arguments for the Popen constructor - kwargs -- Additional arguments for the Popen constructor
Returns: Returns:
Number of failed commands Number of failed commands

View file

@ -23,3 +23,11 @@ commands = flake8 moulinette test
deps = flake8 deps = flake8
skip_install = True skip_install = True
usedevelop = False usedevelop = False
[testenv:docs]
usedevelop = True
commands = python -m sphinx -W doc/ doc/_build
deps =
sphinx
mock
gnupg