diff --git a/Makefile b/Makefile deleted file mode 100644 index a259da8..0000000 --- a/Makefile +++ /dev/null @@ -1,23 +0,0 @@ - -init: - pip install -e . - pip install -r requirements.txt - -docs: - make -C docs html - -test: - pytest - -coverage: - pytest --cov sigal --cov-report term --cov-report=html - -demo: - sigal build -c tests/sample/sigal.conf.py && sigal serve tests/sample/_build - -publish: - python setup.py register - python setup.py sdist bdist_wheel - twine upload dist/* - -.PHONY: docs diff --git a/docs/contribute.rst b/docs/contribute.rst index 498f1dd..cb66e26 100644 --- a/docs/contribute.rst +++ b/docs/contribute.rst @@ -7,7 +7,7 @@ Setting up the development environment -------------------------------------- - Using a virtualenv_:: +Using a virtualenv_:: git clone https://github.com/saimn/sigal.git cd sigal @@ -18,21 +18,27 @@ Install sigal in development mode:: pip install -e . -Install additional dependencies for development (Sphinx, ...):: +Install additional dependencies for development (Sphinx, pytest), and optional +dependencies:: pip install -r requirements.txt Building the docs ----------------- -- Run ``make docs`` (or ``make html`` in the ``docs/`` directory). +- Using tox_, run ``tox -e doc`` +- Or ``make html`` in the ``docs/`` directory. Running the test suite ---------------------- -- Run ``make test`` (or ``pytest``). -- Run ``make coverage`` to get the coverage report. -- Using tox_ you can also run the tests on multiple versions of python. +- Using tox_, run ``tox -e py37`` (replacing ``py37`` with your Python version + if needed). .. _tox: https://tox.readthedocs.io/ .. _virtualenv: https://virtualenv.pypa.io/ + +Building the test gallery +------------------------- + +- Using tox_, run ``tox -e demo`` diff --git a/tox.ini b/tox.ini index dafc6be..7ba264e 100644 --- a/tox.ini +++ b/tox.ini @@ -11,8 +11,6 @@ python = [testenv] deps = -r {toxinidir}/requirements.txt - pytest - pytest-cov commands = pytest --cov sigal --cov-report term-missing tests/ [testenv:check] @@ -35,3 +33,11 @@ deps = usedevelop = true commands = make -C docs html + +[testenv:demo] +usedevelop = true +deps = + feedgenerator +commands = + sigal build -c tests/sample/sigal.conf.py + sigal serve tests/sample/_build