Skip to content

Commit 8cecb7f

Browse files
committed
test for setting log level
Signed-off-by: Jakub Jelen <jjelen@redhat.com>
1 parent a81e1e2 commit 8cecb7f

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tests/unit/session_test.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
"""Tests suite for session."""
44

5+
import logging
56
import pytest
67

78
from pylibsshext.errors import LibsshSessionException
@@ -19,3 +20,10 @@ def test_session_connection_refused(free_port_num):
1920
ssh_session = Session()
2021
with pytest.raises(LibsshSessionException, match=error_msg):
2122
ssh_session.connect(host='127.0.0.1', port=free_port_num)
23+
24+
def test_session_log_level():
25+
"""Test setting the log level"""
26+
ssh_session = Session()
27+
assert ssh_session
28+
29+
ssh_session.set_log_level(logging.DEBUG)

0 commit comments

Comments
 (0)