code: def test_copy_paths(tmp_dir, scm, dvc, tmp):
      stage = dvc.stage.add(
          cmd="cat file && ls dir",
          name="foo",
      )
      scm.add_commit(["dvc.yaml"], message="add dvc.yaml")
  
      (tmp_dir / "dir").mkdir()
      (tmp_dir / "dir" / "file").write_text("dir/file")
      scm.ignore(tmp_dir / "dir")
      (tmp_dir / "file").write_text("file")
      scm.ignore(tmp_dir / "file")
  
      results = dvc.experiments.run(
          stage.addressing, tmp_dir=tmp, copy_paths=["dir", "file"]
      )
      exp = first(results)
      fs = scm.get_fs(exp)
      assert not fs.exists("dir")
      assert not fs.exists("file")
  
imports: import itertools
  import logging
  import os
  import stat
  from textwrap import dedent
  import pytest
  from configobj import ConfigObj
  from funcy import first
  from dvc.dvcfile import PROJECT_FILE
  from dvc.env import DVC_EXP_BASELINE_REV, DVC_EXP_NAME, DVC_ROOT, DVC_STUDIO_OFFLINE, DVC_STUDIO_REPO_URL, DVC_STUDIO_TOKEN, DVC_STUDIO_URL
  from dvc.exceptions import DvcException, ReproductionError
  from dvc.repo.experiments.exceptions import ExperimentExistsError
  from dvc.repo.experiments.queue.base import BaseStashQueue
  from dvc.repo.experiments.refs import CELERY_STASH
  from dvc.repo.experiments.utils import exp_refs_by_rev
  from dvc.scm import SCMError, resolve_rev
  from dvc.stage.exceptions import StageFileDoesNotExistError
  from dvc.testing.scripts import COPY_SCRIPT
  from dvc.utils.serialize import PythonFileCorruptedError
label_desc: Use image node_id 29 for calling a global function with example usage: test_copy_paths(tmp_dir, scm, dvc, tmp) without return types