Commit 14d2b3fe authored by Daniel Scheffler's avatar Daniel Scheffler
Browse files

Updated Makefile.



Signed-off-by: Daniel Scheffler's avatarDaniel Scheffler <danschef@gfz-potsdam.de>
parent 7bdcfe2a
Pipeline #5482 canceled with stage
......@@ -42,13 +42,17 @@ clean-pyc: ## remove Python file artifacts
find . -name '__pycache__' -exec rm -fr {} +
clean-test: ## remove test and coverage artifacts
coverage erase
rm -fr .tox/
rm -f .coverage
rm -fr htmlcov/
rm -fr .pytest_cache
rm -fr nosetests.html
rm -fr nosetests.xml
lint: ## check style with flake8
flake8 sensormapgeo tests
flake8 --max-line-length=120 sensormapgeo tests > ./tests/linting/flake8.log
pycodestyle sensormapgeo --exclude="*.ipynb,*.ipynb*" --max-line-length=120 > ./tests/linting/pycodestyle.log
-pydocstyle sensormapgeo > ./tests/linting/pydocstyle.log
test: ## run tests quickly with the default Python
python setup.py test
......@@ -56,11 +60,18 @@ test: ## run tests quickly with the default Python
test-all: ## run tests on every Python version with tox
tox
coverage: ## check code coverage quickly with the default Python
coverage: clean-test ## check code coverage quickly with the default Python
coverage run --source sensormapgeo setup.py test
coverage report -m
coverage html
$(BROWSER) htmlcov/index.html
# $(BROWSER) htmlcov/index.html
nosetests: clean-test ## Runs nosetests with coverage, xUnit and nose-html-output
## - puts the coverage results in the folder 'htmlcov'
## - generates 'nosetests.html' (--with-html)
## - generates 'nosetests.xml' (--with-xunit) which is currently not visualizable by GitLab
nosetests -vv --with-coverage --cover-package=sensormapgeo --cover-erase --cover-html --cover-html-dir=htmlcov \
--with-html --with-xunit --rednose --force-color
docs: ## generate Sphinx HTML documentation, including API docs
rm -f docs/sensormapgeo.rst
......@@ -68,7 +79,9 @@ docs: ## generate Sphinx HTML documentation, including API docs
sphinx-apidoc -o docs/ sensormapgeo
$(MAKE) -C docs clean
$(MAKE) -C docs html
$(BROWSER) docs/_build/html/index.html
# $(MAKE) -C docs latex
# $(MAKE) -C docs latexpdf
# $(BROWSER) docs/_build/html/index.html
servedocs: docs ## compile the docs watching for changes
watchmedo shell-command -p '*.rst' -c '$(MAKE) -C docs html' -R -D .
......@@ -82,4 +95,8 @@ dist: clean ## builds source and wheel package
ls -l dist
install: clean ## install the package to the active Python's site-packages
pip install -r requirements.txt
python setup.py install
gitlab_CI_docker: ## Build a docker image for CI use within gitlab
cd ./tests/CI_docker/; bash ./build_testsuite_image.sh
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment