code: def pytest_configure(config):
      resultlog = config.option.resultlog
      # prevent opening resultlog on slave nodes (xdist)
      if resultlog and not hasattr(config, "slaveinput"):
          dirname = os.path.dirname(os.path.abspath(resultlog))
          if not os.path.isdir(dirname):
              os.makedirs(dirname)
          logfile = open(resultlog, "w", 1)  # line buffered
          config._resultlog = ResultLog(config, logfile)
          config.pluginmanager.register(config._resultlog)
  
          from _pytest.deprecated import RESULT_LOG
          from _pytest.warnings import _issue_warning_captured
  
          _issue_warning_captured(RESULT_LOG, config.hook, stacklevel=2)
  
file_path: catboost/contrib/python/pytest/py2/_pytest/resultlog.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import os
  import py
label_desc: Use image node_id 2 for calling a global function with example usage: pytest_configure(config) without return types