This commit is contained in:
@@ -42,7 +42,7 @@ func TestExtractTicketID(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestDashboardTemplateParses(t *testing.T) {
|
||||
if _, err := template.ParseFS(files, "templates/dashboard.html"); err != nil {
|
||||
if _, err := template.ParseFS(files, "templates/*.html"); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
@@ -171,3 +171,15 @@ func TestDashboardContainsControlCenterSections(t *testing.T) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestDiagnosticsTemplateAndKnowledgeSearch(t *testing.T) {
|
||||
h, _ := newKnowledgeTestServer(t)
|
||||
rr := httptest.NewRecorder()
|
||||
h.ServeHTTP(rr, httptest.NewRequest(http.MethodGet, "/diagnostics", nil))
|
||||
if rr.Code != http.StatusOK {
|
||||
t.Fatalf("diagnostics = %d: %s", rr.Code, rr.Body.String())
|
||||
}
|
||||
if !bytes.Contains(rr.Body.Bytes(), []byte("Entscheidungsdiagnose")) {
|
||||
t.Fatal("diagnostics page missing title")
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user