summaryrefslogtreecommitdiff
path: root/tests/unit/utils/test_log.py
diff options
context:
space:
mode:
authorFlorian Bruhin <me@the-compiler.org>2020-06-11 12:34:50 +0200
committerFlorian Bruhin <me@the-compiler.org>2020-06-11 12:34:50 +0200
commit33dd70dae67ce051c46fc8a1631e2a5fd94f50b8 (patch)
treee3f72a4c8b8e04c5cb7a79bfe4d922651b32b012 /tests/unit/utils/test_log.py
parent679eaab28f6ee470bfdd7ca3699efdb619b23ebe (diff)
downloadqutebrowser-33dd70dae67ce051c46fc8a1631e2a5fd94f50b8.tar.gz
qutebrowser-33dd70dae67ce051c46fc8a1631e2a5fd94f50b8.zip
Revert "tests: Separate init_from_config logs in utils.test_log"
Whoops... It uses fixtures from that test class! This reverts commit a9d10aee8403fdfcfc68d38a40312c7811d0dfe7.
Diffstat (limited to 'tests/unit/utils/test_log.py')
-rw-r--r--tests/unit/utils/test_log.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/tests/unit/utils/test_log.py b/tests/unit/utils/test_log.py
index 3e3243e48..6b770ed44 100644
--- a/tests/unit/utils/test_log.py
+++ b/tests/unit/utils/test_log.py
@@ -255,16 +255,14 @@ class TestInitLog:
with pytest.raises(PendingDeprecationWarning):
warnings.warn("test warning", PendingDeprecationWarning)
-
-class TestInitFromConfig:
-
@pytest.mark.parametrize('cli, conf, expected', [
(None, 'info', logging.INFO),
(None, 'warning', logging.WARNING),
('info', 'warning', logging.INFO),
('warning', 'info', logging.WARNING),
])
- def test_console(self, cli, conf, expected, args, config_stub):
+ def test_init_from_config_console(self, cli, conf, expected, args,
+ config_stub):
args.debug = False
args.loglevel = cli
log.init_log(args)
@@ -279,7 +277,7 @@ class TestInitFromConfig:
('info', logging.INFO),
('critical', logging.CRITICAL),
])
- def test_ram(self, conf, expected, args, config_stub):
+ def test_init_from_config_ram(self, conf, expected, args, config_stub):
args.debug = False
log.init_log(args)
@@ -287,7 +285,7 @@ class TestInitFromConfig:
log.init_from_config(config_stub.val)
assert log.ram_handler.level == expected
- def test_consistent_default(self, config_stub):
+ def test_init_from_config_consistent_default(self, config_stub):
"""Ensure config defaults are consistent with the builtin defaults."""
args = qutebrowser.get_argparser().parse_args([])
log.init_log(args)