Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions pkg/test/ginkgo/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ func (s *testSuiteProgress) TestEnded(testName string, testRunResult *testRunRes
s.lock.Lock()
defer s.lock.Unlock()

if testRunResult == nil {
return
}

if isTestFailed(testRunResult.testState) {
s.failures++
}
Expand Down
8 changes: 8 additions & 0 deletions pkg/test/ginkgo/test_runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,10 @@ func recordTestResultInLogWithoutOverlap(testRunResult *testRunResultHandle, tes
}

func recordTestResultInLog(testRunResult *testRunResultHandle, out io.Writer, includeSuccessfulOutput bool) {
if testRunResult == nil {
return
}

// output the status of the test
switch testRunResult.testState {
case TestFlaked:
Expand Down Expand Up @@ -257,6 +261,10 @@ func recordTestResultInLog(testRunResult *testRunResultHandle, out io.Writer, in
}

func recordTestResultInMonitor(testRunResult *testRunResultHandle, monitorRecorder monitorapi.Recorder) {
if testRunResult == nil {
return
}

eventLevel := monitorapi.Warning

msg := monitorapi.NewMessage().HumanMessage("e2e test finished")
Expand Down