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

Fix runner for Ruby setup on GitHub Actions #120

Merged
merged 4 commits into from
Jul 2, 2024
Merged

Fix runner for Ruby setup on GitHub Actions #120

merged 4 commits into from
Jul 2, 2024

Conversation

tombruijn
Copy link
Member

Fix diagnose output matcher

I got this error when performing this spec. Match a String instead so the error goes away.

RegexpError: empty char-class

Ignore DidYouMean output in the Ruby runner

It would fail on this line of output being present, so ignore it.

Explicitly run bundle install for Ruby runner

Not sure how it worked before, but explicitly install the runner's gems from the Gemfile, which includes the Ruby gem it's testing. I ran into errors of the gem not being found.

Fix bundler env being copied to Ruby runner

Fix issues with the wrong bundle of gems being used as context for the runner. This failed to find the Ruby gem as it was using this project's test suite Gemfile instead.

Wrap commands with Bundler.with_unbundled_env so it removes any Bundler context from the environment. It also clears some other env vars, so explicitly set them again in the base run_env method.

tombruijn added 3 commits July 2, 2024 09:41
I got this error when performing this spec. Match a String instead
so the error goes away.

> RegexpError: empty char-class
It would fail on this line of output being present, so ignore it.
Not sure how it worked before, but explicitly install the runner's gems
from the Gemfile, which includes the Ruby gem it's testing. I ran into
errors of the gem not being found.
Fix issues with the wrong bundle of gems being used as context for the
runner. This failed to find the Ruby gem as it was using this project's
test suite Gemfile instead.

Wrap commands with `Bundler.with_unbundled_env` so it removes any
Bundler context from the environment. It also clears some other env
vars, so explicitly set them again in the base `run_env` method.
@tombruijn tombruijn merged commit e03053c into main Jul 2, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants