Skip to content

Commit

Permalink
formating
Browse files Browse the repository at this point in the history
  • Loading branch information
csm10495 committed Feb 24, 2024
1 parent c4bb584 commit 12f91e9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion csmlog/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
UdpHandlerReceiver,
LoggedSystemCall,
setup,
CSMLOG_DEFAULT_SAVE_DIRECTORY
CSMLOG_DEFAULT_SAVE_DIRECTORY,
)

APPNAME = "csmlog_test"
Expand Down
14 changes: 10 additions & 4 deletions csmlog/tests/test_csmlog.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,13 @@
import pytest

sys.path.append(os.path.dirname(os.path.abspath(__file__)))
from conftest import APPNAME, CSMLogger, UdpHandlerReceiver, LoggedSystemCall, CSMLOG_DEFAULT_SAVE_DIRECTORY
from conftest import (
APPNAME,
CSMLogger,
UdpHandlerReceiver,
LoggedSystemCall,
CSMLOG_DEFAULT_SAVE_DIRECTORY,
)


def test_get_logger_and_clear_logs(csmlog):
Expand Down Expand Up @@ -240,9 +246,9 @@ def _tmp(logger):

def test_get_default_save_directory_with_name_override(monkeypatch, tmp_path):
monkeypatch.setenv("CSMLOG_DEFAULT_SAVE_DIRECTORY", str(tmp_path))
test123 = tmp_path / 'test123'
assert CSMLogger.getDefaultSaveDirectoryWithName('test123') == str(test123)
test123 = tmp_path / "test123"
assert CSMLogger.getDefaultSaveDirectoryWithName("test123") == str(test123)
assert test123.is_dir()

# calling a second time doesn't cause an issue.
assert CSMLogger.getDefaultSaveDirectoryWithName('test123') == str(test123)
assert CSMLogger.getDefaultSaveDirectoryWithName("test123") == str(test123)

0 comments on commit 12f91e9

Please sign in to comment.