code: def test_stage_load_file_exists_but_dvcignored(
      tmp_dir, dvc, scm, file
  ):
      (tmp_dir / file).write_text("")
      (tmp_dir / ".dvcignore").write_text(file)
  
      dvc._reset()
      dvcfile = load_file(dvc, file)
      with pytest.raises(StageFileDoesNotExistError) as exc_info:
          assert dvcfile.stages.values()
  
      assert str(exc_info.value) == f"'{file}' is dvc-ignored"
  
file_path: dvc/tests/unit/test_dvcfile.py
imports: import pytest
  from dvc.dvcfile import LOCK_FILE, PROJECT_FILE, FileIsGitIgnored, ProjectFile, SingleStageFile, load_file
  from dvc.stage import PipelineStage
  from dvc.stage.exceptions import StageFileDoesNotExistError, StageFileIsNotDvcFileError
  from dvc.utils.fs import remove
  from dvc.utils.serialize import EncodingError
  from dvc.utils.strictyaml import YAMLValidationError
label_desc: Use image node_id 7 for calling a global function with example usage: test_stage_load_file_exists_but_dvcignored(tmp_dir, dvc, scm, file) without return types