Skip to content

Commit

Permalink
feat: support downloading network.har and crash.json (#954)
Browse files Browse the repository at this point in the history
  • Loading branch information
tianfeng92 authored Oct 9, 2024
1 parent 1754b39 commit 2c1e00f
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions internal/http/rdcservice.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ type rdcJob struct {
DeviceLogURL string `json:"device_log_url,omitempty"`
TestCasesURL string `json:"test_cases_url,omitempty"`
VideoURL string `json:"video_url,omitempty"`
NetworkLogURL string `json:"network_log_url,omitempty"`
CrashLogURL string `json:"crash_log_url,omitempty"`
Screenshots []struct {
ID string
} `json:"screenshots,omitempty"`
Expand Down Expand Up @@ -310,6 +312,12 @@ func (c *RDCService) GetJobAssetFileNames(ctx context.Context, jobID string, rea
if strings.HasSuffix(jr.VideoURL, "/video.mp4") {
files = append(files, "video.mp4")
}
if strings.HasSuffix(jr.NetworkLogURL, "/network.har") {
files = append(files, "network.har")
}
if strings.HasSuffix(jr.CrashLogURL, "/crash.json") {
files = append(files, "crash.json")
}
if len(jr.Screenshots) > 0 {
files = append(files, "screenshots.zip")
}
Expand Down

0 comments on commit 2c1e00f

Please sign in to comment.