Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix.ensure logger set for all caplog.set level #5920

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion tests/unit/test_flow_mgr.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

from cylc.flow.flow_mgr import FlowMgr
from cylc.flow.workflow_db_mgr import WorkflowDatabaseManager
from cylc.flow import CYLC_LOG


FAKE_NOW = datetime.datetime(2020, 12, 25, 17, 5, 55)
Expand All @@ -44,7 +45,7 @@ def test_all(
):
db_mgr = WorkflowDatabaseManager()
flow_mgr = FlowMgr(db_mgr)
caplog.set_level(logging.INFO)
caplog.set_level(logging.INFO, CYLC_LOG)

count = 1
meta = "the quick brown fox"
Expand Down
3 changes: 2 additions & 1 deletion tests/unit/test_id_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
from pathlib import Path
import pytest

from cylc.flow import CYLC_LOG
from cylc.flow.async_util import pipe
from cylc.flow.exceptions import InputError, WorkflowFilesError
from cylc.flow.id import detokenise, tokenise, Tokens
Expand Down Expand Up @@ -537,7 +538,7 @@ def test_validate_workflow_ids_basic(tmp_run_dir):

def test_validate_workflow_ids_warning(caplog):
"""It should warn when the run number is provided as a cycle point."""
caplog.set_level(logging.WARN)
caplog.set_level(logging.WARN, CYLC_LOG)
_validate_workflow_ids(Tokens('workflow/run1//cycle/task'), src_path='')
assert caplog.messages == []

Expand Down