package infra import ( "strings" "testing" ) // `09` §3 decision 36 — the kept-data source appears only when named, at /srv/megorzott. func TestFileBrowser_KeptSourceOnlyWhenNamed(t *testing.T) { if s := RenderFileBrowserConfigKept(nil, false, ""); strings.Contains(s, FileBrowserKeptMount) { t.Fatal("a kept source rendered with no label") } s := RenderFileBrowserConfigKept(nil, false, "Megőrzött adatok") if !strings.Contains(s, `path: "/srv/`+FileBrowserKeptMount+`"`) || !strings.Contains(s, `name: "Megőrzött adatok"`) { t.Fatalf("kept source missing:\n%s", s) } }