MCPcopy
hub / github.com/vinta/awesome-python / test_build_cleans_stale_output

Method test_build_cleans_stale_output

website/tests/test_build.py:364–386  ·  view source on GitHub ↗
(self, tmp_path)

Source from the content-addressed store, hash-verified

362 assert "# Contributing" not in llms_txt
363
364 def test_build_cleans_stale_output(self, tmp_path):
365 readme = textwrap.dedent("""\
366 # T
367
368 ## Projects
369
370 ## Only
371
372 - [x](https://x.com) - X.
373
374 # Contributing
375
376 Done.
377 """)
378 self._make_repo(tmp_path, readme)
379
380 stale = tmp_path / "website" / "output" / "categories" / "stale"
381 stale.mkdir(parents=True)
382 (stale / "index.html").write_text("old", encoding="utf-8")
383
384 build(tmp_path)
385
386 assert not (tmp_path / "website" / "output" / "categories" / "stale").exists()
387
388 def test_build_with_stars_sorts_by_stars(self, tmp_path):
389 readme = textwrap.dedent("""\

Callers

nothing calls this directly

Calls 2

_make_repoMethod · 0.95
buildFunction · 0.90

Tested by

no test coverage detected