summaryrefslogtreecommitdiff
path: root/tests/test_custom_logger.py
diff options
context:
space:
mode:
authorDavid Luevano Alvarado <david@luevano.xyz>2023-02-21 21:02:23 -0600
committerDavid Luevano Alvarado <david@luevano.xyz>2023-02-21 21:02:23 -0600
commit28c2ae9102d4204b3f0a79419eec1e72dbbc529a (patch)
treee93b4034371bc569f2a528db6cd5ad29afd9b001 /tests/test_custom_logger.py
parentf2ab2bac6b26f82730d5f5d7ab1e6d5f2f1060e3 (diff)
add configuration testing, small refactor
Diffstat (limited to 'tests/test_custom_logger.py')
-rw-r--r--tests/test_custom_logger.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/test_custom_logger.py b/tests/test_custom_logger.py
index 1062e41..9102f52 100644
--- a/tests/test_custom_logger.py
+++ b/tests/test_custom_logger.py
@@ -1,6 +1,5 @@
import pytest
-from logging import DEBUG, INFO, WARNING, ERROR, CRITICAL
-from typing import Callable
+from logging import Logger, DEBUG, INFO, WARNING, ERROR, CRITICAL
@pytest.mark.parametrize('log_level, starts_with, message', [
@@ -13,7 +12,7 @@ from typing import Callable
def test_log_levels(log_level: int,
starts_with: str,
message: str,
- logger: Callable,
+ logger: Logger,
capture_stdout: dict[str, str | int]) -> None:
logger.log(log_level, message)
assert str(capture_stdout['stdout']).startswith(starts_with)