Refactor LDAP tests (#37274)

Not really fix #37263, just make things better, and easy to catch more
clues if it would fail again.
This commit is contained in:
wxiaoguang
2026-04-19 03:32:49 +08:00
committed by GitHub
parent 0824610e39
commit af31b9d433
6 changed files with 151 additions and 167 deletions
+1 -1
View File
@@ -404,7 +404,7 @@ func logUnexpectedResponse(t testing.TB, recorder *httptest.ResponseRecorder) {
if err != nil {
return // probably a non-HTML response
}
errMsg := htmlDoc.Find(".ui.negative.message").Text()
errMsg := htmlDoc.Find(".ui.negative.message:not(.tw-hidden)").Text()
if len(errMsg) > 0 {
t.Log("A flash error message was found:", errMsg)
}