Skip to content

[junit upload] Fix wrongly processed glob patterns#1315

Merged
juan-fernandez merged 4 commits intomasterfrom
juan-fernandez/fix-glob-patterns
May 28, 2024
Merged

[junit upload] Fix wrongly processed glob patterns#1315
juan-fernandez merged 4 commits intomasterfrom
juan-fernandez/fix-glob-patterns

Conversation

@juan-fernandez
Copy link
Copy Markdown
Contributor

@juan-fernandez juan-fernandez commented May 27, 2024

What and why?

Fixes #1304

How?

We make sure that buildPath is not called when not necessary.

Additionally we've also improved testing of the GHA in DataDog/junit-upload-github-action#17

Review checklist

  • Feature or bugfix MUST have appropriate tests (unit, integration)

@juan-fernandez juan-fernandez changed the title fix glob patterns [junit upload] Fix wrongly processed glob patterns May 27, 2024
@juan-fernandez juan-fernandez added the software-delivery Related to [coverage, deployment, dora, junit, measure, tag, trace] label May 27, 2024
@datadog-datadog-prod-us1
Copy link
Copy Markdown

Datadog Report

Branch report: juan-fernandez/fix-glob-patterns
Commit report: fb46329
Test service: datadog-ci-tests

✅ 0 Failed, 240 Passed, 0 Skipped, 1m 31.34s Total duration (1m 26.22s time saved)

- name: Run junit upload test (metrics)
run: yarn datadog-ci junit upload --service=datadog-ci-e2e-tests-junit artifacts/e2e/junit-reports --metrics testmeasure2:60 --report-metrics sessionmeasure2:80
- name: Run junit upload test (metrics), passing glob as literal string
run: yarn datadog-ci junit upload --service=datadog-ci-e2e-tests-junit '**/junit-reports/**' --metrics testmeasure2:60 --report-metrics sessionmeasure2:80
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by passing quotation marks the pattern is not expanded and is managed by the CLI. This makes for a more complete test and also helps testing the usage of https://github.com/DataDog/junit-upload-github-action/

Copy link
Copy Markdown
Contributor

@Drarig29 Drarig29 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@juan-fernandez juan-fernandez merged commit 9191b61 into master May 28, 2024
@juan-fernandez juan-fernandez deleted the juan-fernandez/fix-glob-patterns branch May 28, 2024 11:07
@Drarig29 Drarig29 mentioned this pull request May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

software-delivery Related to [coverage, deployment, dora, junit, measure, tag, trace]

Projects

None yet

Development

Successfully merging this pull request may close these issues.

We are not pulling junits from nested folders for multi module setup

3 participants