MCPcopy Index your code
hub / github.com/HelloZeroNet/ZeroNet / testList

Method testList

src/Test/TestSiteStorage.py:15–22  ·  view source on GitHub ↗
(self, site)

Source from the content-addressed store, hash-verified

13 assert list(site.storage.walk("data-default")) == ["data.json", "users/content-default.json"]
14
15 def testList(self, site):
16 # Rootdir
17 list_root = list(site.storage.list(""))
18 assert "content.json" in list_root
19 assert "css/all.css" not in list_root
20
21 # Subdir
22 assert set(site.storage.list("data-default")) == set(["data.json", "users"])
23
24 def testDbRebuild(self, site):
25 assert site.storage.rebuildDb()

Callers

nothing calls this directly

Calls 1

listMethod · 0.45

Tested by

no test coverage detected