From 605763e38bf72b5c20acf305c74f36f8d2d42d60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mislav=20Cimpers=CC=8Cak?= Date: Mon, 2 Oct 2017 21:53:37 +0200 Subject: [PATCH] pytest init --- .coveragerc | 9 +++++++++ pytest.ini | 3 +++ requirements_testing.txt | 5 +++++ tests/__init__.py | 0 tests/test_function.py | 2 ++ 5 files changed, 19 insertions(+) create mode 100644 .coveragerc create mode 100644 pytest.ini create mode 100644 requirements_testing.txt create mode 100644 tests/__init__.py create mode 100644 tests/test_function.py diff --git a/.coveragerc b/.coveragerc new file mode 100644 index 0000000..472ae9b --- /dev/null +++ b/.coveragerc @@ -0,0 +1,9 @@ +[run] +branch = True +source = . + +[report] +show_missing = True +omit = + */tests/* + */test_*.py diff --git a/pytest.ini b/pytest.ini new file mode 100644 index 0000000..d05470b --- /dev/null +++ b/pytest.ini @@ -0,0 +1,3 @@ +[pytest] +addopts = --cov +python_files = tests* test_*.py diff --git a/requirements_testing.txt b/requirements_testing.txt new file mode 100644 index 0000000..5401448 --- /dev/null +++ b/requirements_testing.txt @@ -0,0 +1,5 @@ +-r requirements.txt + +pytest +pytest-cov +pytest-sugar diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_function.py b/tests/test_function.py new file mode 100644 index 0000000..97144eb --- /dev/null +++ b/tests/test_function.py @@ -0,0 +1,2 @@ +def test_dummy(): + assert 1 + 1 == 2