-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add option to download matching artifacts for all job attempts (#…
…937) * Download based on attempt not last jobData * Download artifacts after an attempt * Remove unneeded properties * Add artifacts to result * Have downloader handle all logic * cleanup * Cleanup args list * Cleanup * fixup test mocks * update test * update schema * lint * add option to other schema * add cli flag for allAttempts * Update internal/saucecloud/downloader/downloader.go Co-authored-by: Alex Plischke <[email protected]> * fixup test * lint --------- Co-authored-by: Alex Plischke <[email protected]>
- Loading branch information
1 parent
04e0196
commit f00fcc8
Showing
13 changed files
with
88 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,13 @@ | ||
package mocks | ||
|
||
import "github.com/saucelabs/saucectl/internal/job" | ||
|
||
// FakeArtifactDownloader defines a fake Downloader | ||
type FakeArtifactDownloader struct { | ||
DownloadArtifactFn func(jobID, suiteName string) []string | ||
DownloadArtifactFn func(jobData job.Job, attempt int, retries int) []string | ||
} | ||
|
||
// DownloadArtifact defines a fake function for FakeDownloader | ||
func (f *FakeArtifactDownloader) DownloadArtifact(jobID, suiteName string, realDevice bool) []string { | ||
return f.DownloadArtifactFn(jobID, suiteName) | ||
func (f *FakeArtifactDownloader) DownloadArtifact(jobData job.Job, attempt int, retries int) []string { | ||
return f.DownloadArtifactFn(jobData, attempt, retries) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters