Skip to content

Commit

Permalink
feat: make docs generation part of tox (#155)
Browse files Browse the repository at this point in the history
Testing docs should be expanded in future.
  • Loading branch information
Midnighter committed Aug 11, 2017
1 parent cbda12d commit 887ac4c
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 6 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ matrix:
include:
- python: 3.5
env: TOXENV=flake8
- python: 3.5
env: TOXENV=docs
- python: 2.7
env: TOXENV=py27
- python: 3.4
Expand Down
8 changes: 3 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ lint: ## check style with flake8
flake8 memote tests

test: ## run tests quickly with the default Python
py.test
pytest tests/

test-all: ## run tests on every Python version with tox
tox
Expand All @@ -74,12 +74,10 @@ servedocs: docs ## compile the docs watching for changes
watchmedo shell-command -p '*.rst' -c '$(MAKE) -C docs html' -R -D .

release: clean ## package and upload a release
python setup.py sdist upload
python setup.py bdist_wheel upload
python setup.py sdist bdist_wheel upload

dist: clean ## builds source and wheel package
python setup.py sdist
python setup.py bdist_wheel
python setup.py sdist bdist_wheel
ls -l dist

install: clean ## install the package to the active Python's site-packages
Expand Down
3 changes: 3 additions & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
Sphinx
numpydoc
sphinx-bootstrap-theme
numpy
pandas
plotly
11 changes: 10 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = flake8, py27, py34, py35, py36
envlist = flake8, docs, py27, py34, py35, py36
skip_missing_interpreters = True

[testenv]
Expand Down Expand Up @@ -27,6 +27,15 @@ deps=
commands=
flake8 memote

[testenv:docs]
skip_install = True
deps=
-r{toxinidir}/docs/requirements.txt
whitelist_externals =
make
commands=
make docs

; If you want to make tox run the tests with the same versions, create a
; requirements.txt with the pinned versions and uncomment the following lines:
; deps =
Expand Down

0 comments on commit 887ac4c

Please sign in to comment.