docstr: .cfg files with [pytest] section are no longer supported and should fail to alert users
docstr_tok: [".cfg","files","with","[","pytest","]","section","are","no","longer","supported","and","should","fail","to","alert","users"]
code: def test_unsupported_pytest_section_in_cfg_file(
      self, tmp_path: Path
  ) -> None:
      """.cfg files with [pytest] section are no longer supported and should fail to alert users"""
      fn = tmp_path / "custom.cfg"
      fn.write_text("[pytest]", encoding="utf-8")
      with pytest.raises(pytest.fail.Exception):
          load_config_dict_from_file(fn)
  
imports: import os
  from pathlib import Path
  from textwrap import dedent
  import pytest
  from _pytest.config import UsageError
  from _pytest.config.findpaths import get_common_ancestor
  from _pytest.config.findpaths import get_dirs_from_args
  from _pytest.config.findpaths import is_fs_root
  from _pytest.config.findpaths import load_config_dict_from_file
label_desc: Use image node_id 7 for calling the TestLoadConfigDictFromFile obj's underlying member method code with example usage: obj.test_unsupported_pytest_section_in_cfg_file(tmp_path) without return types