Preserve empty smoke error messages in aggregate reports
This commit is contained in:
@@ -101,7 +101,7 @@ type smokeAggregateDTO struct {
|
||||
type smokeResultDTO struct {
|
||||
Kind promptkit.SmokeTestKind `yaml:"kind"`
|
||||
Report *smokeReportDTO `yaml:"report"`
|
||||
Error string `yaml:"error,omitempty"`
|
||||
Error *string `yaml:"error,omitempty"`
|
||||
}
|
||||
|
||||
type smokeResult struct {
|
||||
@@ -122,7 +122,8 @@ func encodeSmokeResults(results []smokeResult) ([]byte, error) {
|
||||
Report: smokeReportFromNative(result.Report),
|
||||
}
|
||||
if result.Err != nil {
|
||||
entries[index].Error = result.Err.Error()
|
||||
message := result.Err.Error()
|
||||
entries[index].Error = &message
|
||||
}
|
||||
}
|
||||
return encodePromptYAMLBytes(smokeAggregateDTO{Tests: entries})
|
||||
|
||||
Reference in New Issue
Block a user