class_docstr: Attaches to the logging module and captures log messages for each test.
      
class_docstr_tok: ["Attaches","to","the","logging","module","and","captures","log","messages","for","each","test","."]
docstr: Public method, which can set filename parameter for
  Logging.FileHandler(). Also creates parent directory if
  it does not exist.
  
  .. warning::
      Please considered as an experimental API.
docstr_tok: ["Public","method",",","which","can","set","filename","parameter","for","Logging.FileHandler","(",")",".","Also","creates","parent","directory","if","it","does","not","exist",".","..","warning",":",":","Please","considered","as","an","experimental","API","."]
code: def set_log_path(self, fname):
      """Public method, which can set filename parameter for
      Logging.FileHandler(). Also creates parent directory if
      it does not exist.
  
      .. warning::
          Please considered as an experimental API.
      """
      fname = Path(fname)
  
      if not fname.is_absolute():
          fname = Path(self._config.rootdir, fname)
  
      if not fname.parent.exists():
          fname.parent.mkdir(exist_ok=True, parents=True)
  
      self.log_file_handler = logging.FileHandler(
          str(fname), mode="w", encoding="UTF-8"
      )
      self.log_file_handler.setFormatter(self.log_file_formatter)
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import logging
  import re
  from contextlib import contextmanager
  import py
  import six
  import pytest
  from _pytest.compat import dummy_context_manager
  from _pytest.config import create_terminal_writer
  from _pytest.pathlib import Path
label_desc: Use image node_id 4 for calling the LoggingPlugin obj's underlying member method code with example usage: obj.set_log_path(fname) without return types