Skip to content

Commit

Permalink
Fix pytest settings
Browse files Browse the repository at this point in the history
  • Loading branch information
jacebrowning committed Mar 7, 2022
1 parent 5b5e317 commit 886c1c4
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 18 deletions.
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,9 @@ PYTEST_OPTIONS := --random --random-seed=$(RANDOM_SEED)
ifndef DISABLE_COVERAGE
PYTEST_OPTIONS += --cov=$(PACKAGE)
endif
ifdef CI
PYTEST_OPTIONS += --cov-report=xml
endif
PYTEST_RERUN_OPTIONS := --last-failed --exitfirst

.PHONY: test
Expand Down
5 changes: 4 additions & 1 deletion bin/update
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# -*- coding: utf-8 -*-

import os
from contextlib import suppress
import importlib
import tempfile
import shutil
Expand Down Expand Up @@ -48,6 +49,7 @@ def run():

def copy():
for filename in [
'.appveyor.yml',
'.coveragerc',
'.gitattributes',
'.gitignore',
Expand All @@ -66,7 +68,8 @@ def copy():
src = os.path.join(TMP, CONFIG['project_name'], filename)
dst = os.path.join(CWD, filename)
print("Updating " + filename)
shutil.copy(src, dst)
with suppress(FileNotFoundError):
shutil.copy(src, dst)


if __name__ == '__main__':
Expand Down
15 changes: 0 additions & 15 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -88,15 +88,14 @@ check_untyped_defs = true

cache_dir = ".cache/mypy/"

[tool.pytest]
[tool.pytest.ini_options]

addopts = """
--strict-markers
-r sxX
--show-capture=log
--cov-report=xml
--cov-report=html
--cov-report=term-missing:skip-covered
--no-cov-on-fail
Expand Down

0 comments on commit 886c1c4

Please sign in to comment.