Initial import: Music_Server, MusicFree, catalog-sync
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
import unittest
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
REPO_ROOT = Path(__file__).resolve().parents[1]
|
||||
DEPLOY_DOC = REPO_ROOT / "docs" / "nas-docker-deployment.md"
|
||||
SPEC_DOC = (
|
||||
REPO_ROOT
|
||||
/ "docs"
|
||||
/ "superpowers"
|
||||
/ "specs"
|
||||
/ "2026-04-19-music-cloud-public-music-service-design.md"
|
||||
)
|
||||
|
||||
LEGACY_APP = "/volume4/Music_Server/app"
|
||||
TARGET_ROOT = "/volume4/Music_Cloud/Music_Server"
|
||||
TARGET_APP = "/volume4/Music_Cloud/Music_Server/app"
|
||||
REQUIRED_SPEC_ITEMS = (
|
||||
"/volume4/Music_Cloud",
|
||||
"/volume4/Music_Cloud/catalogsync",
|
||||
"/volume4/Music_Cloud/catalogsync/data/catalogsync.db",
|
||||
"/volume4/Music_Cloud/library",
|
||||
"/volume4/Music_Cloud/playlists",
|
||||
"catalogsync serve",
|
||||
)
|
||||
|
||||
|
||||
class NasDeploymentPathTests(unittest.TestCase):
|
||||
def test_docs_use_music_cloud_host_root(self):
|
||||
deploy_text = DEPLOY_DOC.read_text(encoding="utf-8")
|
||||
spec_text = SPEC_DOC.read_text(encoding="utf-8")
|
||||
|
||||
self.assertIn(TARGET_ROOT, deploy_text)
|
||||
self.assertIn(TARGET_APP, deploy_text)
|
||||
self.assertNotIn(LEGACY_APP, deploy_text)
|
||||
|
||||
self.assertIn(TARGET_ROOT, spec_text)
|
||||
self.assertIn(TARGET_APP, spec_text)
|
||||
self.assertNotIn(LEGACY_APP, spec_text)
|
||||
for item in REQUIRED_SPEC_ITEMS:
|
||||
self.assertIn(item, spec_text)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
Reference in New Issue
Block a user