Skip to content

Commit

Permalink
Handle error for 0 doc hits for a data stream (#744)
Browse files Browse the repository at this point in the history
* Fix panic caused when there are no doc hits for a data stream 
   during system tests.
  • Loading branch information
r00tu53r authored Mar 28, 2022
1 parent 8476aec commit 87d3cdd
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions internal/testrunner/runners/system/runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,7 @@ func (r *runner) runTest(config *testConfig, ctxt servicedeployer.ServiceContext

if !passed {
result.FailureMsg = fmt.Sprintf("could not find hits in %s data stream", dataStream)
return result.WithError(fmt.Errorf("%s", result.FailureMsg))
}

// Validate fields in docs
Expand Down

0 comments on commit 87d3cdd

Please sign in to comment.