Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support downloading network.har and crash.json #954

Merged
merged 1 commit into from
Oct 9, 2024
Merged
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
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
Loading