Skip to content

Commit

Permalink
chore: more debug logs for sandbox
Browse files Browse the repository at this point in the history
  • Loading branch information
devcatalin committed Oct 2, 2024
1 parent 05dd832 commit 4a2ad57
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions cmd/testworkflow-toolkit/artifacts/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ func (h *handler) Add(path string, file fs.File, stat fs.FileInfo) (err error) {
fmt.Printf(ui.Red("%s: failed: %s"), uploadPath, err.Error())
}
if h.postProcessor != nil {
fmt.Printf("Path sent to post processor: %s\n", ui.LightCyan(path))
err = h.postProcessor.Add(path)
if err != nil {
h.errors.Add(1)
Expand Down
1 change: 1 addition & 0 deletions cmd/testworkflow-toolkit/artifacts/junit_post_processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ func (p *JUnitPostProcessor) Start() error {
// Add checks if the file is a JUnit report and sends it to the cloud.
func (p *JUnitPostProcessor) Add(path string) error {
fmt.Printf("Checking file: %s\n", ui.LightCyan(path))
fmt.Printf("Path prefix: %s\n", ui.LightCyan(p.pathPrefix))
uploadPath := path
if p.pathPrefix != "" {
uploadPath = filepath.Join(p.pathPrefix, uploadPath)
Expand Down
1 change: 1 addition & 0 deletions cmd/testworkflow-toolkit/commands/artifacts.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ func NewArtifactsCmd() *cobra.Command {
defer executor.Close()

if env.JUnitParserEnabled() || capabilities.Enabled(supported, capabilities.CapabilityJUnitReports) {
fmt.Printf("FSPrefix: %s\n", env.Config().Execution.FSPrefix)
junitProcessor := artifacts.NewJUnitPostProcessor(filesystem.NewOSFileSystem(), executor, walker.Root(), env.Config().Execution.FSPrefix)
handlerOpts = append(handlerOpts, artifacts.WithPostProcessor(junitProcessor))
}
Expand Down

0 comments on commit 4a2ad57

Please sign in to comment.