Collect existing tests in pytest runner

Ensure pytest picks up our python test modules, since we're using
tests_*.py convention, which is different from the default.

Configure pytest logging to display the output from all tests (even the
ones that passed). This ensures we have sufficient amount of information
to debug test post-mortem just from the artifacts.

(cherry picked from commit 08c4e35bc0)
This commit is contained in:
Tom Krizek
2023-01-12 16:26:25 +01:00
parent 9112b51bb9
commit 495216f81c

View File

@@ -0,0 +1,18 @@
# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
#
# SPDX-License-Identifier: MPL-2.0
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, you can obtain one at https://mozilla.org/MPL/2.0/.
#
# See the COPYRIGHT file distributed with this work for additional
# information regarding copyright ownership.
[pytest]
addopts = --tb=short -rA
log_format = %(asctime)s %(levelname)s:%(name)s %(message)s
log_date_format = %Y-%m-%d %H:%M:%S
log_cli = 1
log_level = INFO
python_files = tests_*.py