code: def test_wdir_failed_to_interpolate(tmp_dir, dvc, wdir, expected_msg):
      definition = make_entry_definition(
          tmp_dir,
          "build",
          {"wdir": wdir, "cmd": "echo ${models.bar}"},
          Context(models={"bar": "bar"}),
      )
      with pytest.raises(ResolveError) as exc_info:
          definition.resolve()
  
      assert escape_ansi(str(exc_info.value)) == (
          "failed to parse 'stages.build.wdir' in 'dvc.yaml':"
          + expected_msg
      )
      assert definition.context == {"models": {"bar": "bar"}}
  
imports: import logging
  import re
  import pytest
  from dvc.parsing import ResolveError
  from dvc.parsing.context import Context
  from dvc.parsing.interpolate import embrace
  from dvc.utils.humanize import join
  from .None import make_entry_definition, make_foreach_def
label_desc: Use image node_id 6 for calling a global function with example usage: test_wdir_failed_to_interpolate(tmp_dir, dvc, wdir, expected_msg) without return types