diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7730d4b572b701094b69b95277d964e824eb3d8e..b32a166506354b75b643f234c1416739a855e416 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -14,13 +14,13 @@ before_script: - virtualenv venv - source venv/bin/activate - pip3 install . - # - pip3 install .[tests] + - pip3 install .[tests] linters: script: - pip3 install .[linters] - make check -#tests: -# script: -# - pytest tests +tests: + script: + - pytest tests diff --git a/Makefile b/Makefile index 2afe68fa59506787df0741deb455249010d773f9..7caa8be84371ffb57cbca5327872859817eea403 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -SOURCES=losscalculator setup.py +SOURCES=losscalculator tests setup.py LENGTH=96 check: $(SOURCES) diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..529feb33dc59a579cf9957692d24c5e46be178e7 --- /dev/null +++ b/tests/__init__.py @@ -0,0 +1,17 @@ +#!/usr/bin/python3 + +# Copyright (c) 2020: +# Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ +# +# This program is free software: you can redistribute it and/or modify it +# under the terms of the GNU Affero General Public License as published by +# the Free Software Foundation, either version 3 of the License, or (at +# your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero +# General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. diff --git a/tests/test_lossCalculator.py b/tests/test_lossCalculator.py new file mode 100644 index 0000000000000000000000000000000000000000..e7340cc4281d644fde5f89003742907fe5cc4b33 --- /dev/null +++ b/tests/test_lossCalculator.py @@ -0,0 +1,25 @@ +#!/usr/bin/python3 + +# Copyright (c) 2020: +# Helmholtz-Zentrum Potsdam Deutsches GeoForschungsZentrum GFZ +# +# This program is free software: you can redistribute it and/or modify it +# under the terms of the GNU Affero General Public License as published by +# the Free Software Foundation, either version 3 of the License, or (at +# your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero +# General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see http://www.gnu.org/licenses/. + +import logging + +logger = logging.getLogger() + + +def test_func(): + pass