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

change(review.bats): only run "run" tests on actual run steps #196

Merged

Conversation

danielma
Copy link
Contributor

I know this used to work before, but recently this review has been failing on all my builds.

The issue is that it's attempting to check non "run" steps against the same validation rules, and causing errors that just output null

I've fixed it here by using select to make sure the check only loops through run steps

I know this used to work before, but recently this review has been
failing on all my builds.

The issue is that it's attempting to check non "run" steps against the
same validation rules, and causing errors that just output `null`

I've fixed it here by using `select` to make sure the check only loops
through `run` steps
@danielma danielma requested a review from a team as a code owner March 13, 2023 19:00
@orb-publisher
Copy link

Your development orb has been published. It will expire in 30 days.
You can preview what this will look like on the CircleCI Orb Registry at the following link:
https://circleci.com/developer/orbs/orb/circleci/orb-tools?version=dev:39065431c55b749d1ded9a19d44c16b238522a50

@ankorstore-haddowg
Copy link

ankorstore-haddowg commented Mar 27, 2023

Had the same issue but only running the BATS checks locally, the orb checks in the CI passed 🤷.
seems yq may have altered behaviour? either way this solution or a | select(.has(.run)) | worked for me

@danielma
Copy link
Contributor Author

Yep, there was some YQ behavior change, and the latest version of the orb is actually pinned to an earlier tag #177

@ankorstore-haddowg
Copy link

really think the script should be forward-compatible instead... pinning the image is a bit of an odd response...
I curl the bats file and use it in a local pre-commit hook to review locally and would like to not have to pin my yq.

@KyleTryon
Copy link
Contributor

Ensuring this change will be present in #181 I will close this PR after #181 has been merged. Thank you for sharing.

@KyleTryon
Copy link
Contributor

It looks like I may be able to merge this without conflict. Going to give it a shot, thank you!

@KyleTryon KyleTryon merged commit 9f77feb into CircleCI-Public:master Apr 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants