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

Method test_remove_catalog

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

Source from the content-addressed store, hash-verified

4399 catalog.add_catalog("https://example.com/catalog.json")
4400
4401 def test_remove_catalog(self, project_dir):
4402 from specify_cli.workflows.catalog import WorkflowCatalog
4403
4404 catalog = WorkflowCatalog(project_dir)
4405 catalog.add_catalog("https://example.com/c1.json", "first")
4406 catalog.add_catalog("https://example.com/c2.json", "second")
4407
4408 removed = catalog.remove_catalog(0)
4409 assert removed == "first"
4410
4411 config_path = project_dir / ".specify" / "workflow-catalogs.yml"
4412 data = yaml.safe_load(config_path.read_text())
4413 assert len(data["catalogs"]) == 1
4414
4415 def test_remove_catalog_invalid_index(self, project_dir):
4416 from specify_cli.workflows.catalog import WorkflowCatalog, WorkflowValidationError

Callers

nothing calls this directly

Calls 4

add_catalogMethod · 0.95
remove_catalogMethod · 0.95
WorkflowCatalogClass · 0.90
read_textMethod · 0.80

Tested by

no test coverage detected