We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1f6e6b4 commit 6ede9e4Copy full SHA for 6ede9e4
tests/suite/graceful_recovery_test.go
@@ -280,8 +280,13 @@ func checkContainerLogsForErrors(ngfPodName string) {
280
&core.PodLogOptions{Container: ngfContainerName},
281
)
282
Expect(err).ToNot(HaveOccurred())
283
- if !*plusEnabled {
284
- Expect(logs).ToNot(ContainSubstring("\"level\":\"error\""), logs)
+
+ for _, line := range strings.Split(logs, "\n") {
285
+ if *plusEnabled && strings.Contains(line, "[error]") {
286
+ Expect(line).To(ContainSubstring("Usage reporting must be enabled when using NGINX Plus"), line)
287
+ } else {
288
+ Expect(line).ToNot(ContainSubstring("[error]"), line)
289
+ }
290
}
291
292
0 commit comments