Skip to content

Commit 71596c8

Browse files
committed
use own logger in test framework
1 parent 52a9e41 commit 71596c8

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/pynxtools/testing/nexus_conversion.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,18 +41,18 @@
4141

4242
def get_log_file(nxs_file, log_file, tmp_path):
4343
"""Get log file for the nexus file with read_nexus tools."""
44-
logger = logging.getLogger("pynxtools")
44+
logger = logging.getLogger("pynxtools.reproducibility")
4545
logger.handlers.clear()
4646
logger.setLevel(logging.DEBUG)
47-
log_file = os.path.join(tmp_path, log_file)
48-
handler = logging.FileHandler(log_file, "w")
47+
log_path = os.path.join(tmp_path, log_file)
48+
handler = logging.FileHandler(log_path, "w")
4949
formatter = logging.Formatter("%(levelname)s - %(message)s")
5050
handler.setLevel(logging.DEBUG)
5151
handler.setFormatter(formatter)
5252
logger.addHandler(handler)
5353
nexus_helper = HandleNexus(logger, nxs_file, None, None)
5454
nexus_helper.process_nexus_master_file(None)
55-
return log_file
55+
return log_path
5656

5757

5858
class ReaderTest:

0 commit comments

Comments
 (0)