MCPcopy Index your code
hub / github.com/github/spec-kit / test_skip_symlinked_step_files

Method test_skip_symlinked_step_files

tests/test_workflows.py:5115–5132  ·  view source on GitHub ↗
(self, project_dir)

Source from the content-addressed store, hash-verified

5113
5114 @pytest.mark.skipif(not hasattr(os, "symlink"), reason="symlinks are unavailable")
5115 def test_skip_symlinked_step_files(self, project_dir):
5116 from specify_cli.workflows import load_custom_steps
5117
5118 step_dir = project_dir / ".specify" / "workflows" / "steps" / "bad-symlinked-files"
5119 step_dir.mkdir(parents=True)
5120
5121 outside = project_dir.parent / "outside-step-files"
5122 outside.mkdir(parents=True, exist_ok=True)
5123 step_yml_target = outside / "step.yml"
5124 step_yml_target.write_text("step:\n type_key: bad-symlinked-files\n", encoding="utf-8")
5125 init_target = outside / "__init__.py"
5126 init_target.write_text("# external code", encoding="utf-8")
5127
5128 (step_dir / "step.yml").symlink_to(step_yml_target)
5129 (step_dir / "__init__.py").symlink_to(init_target)
5130
5131 loaded = load_custom_steps(project_dir)
5132 assert "bad-symlinked-files" not in loaded
5133
5134 def test_skip_already_registered(self, project_dir):
5135 from specify_cli.workflows import load_custom_steps

Callers

nothing calls this directly

Calls 1

load_custom_stepsFunction · 0.90

Tested by

no test coverage detected