Failure/Error: require 'base64'
Overview
Whilst running make test, I see:
$ make test
bundle exec rspec --color --format d spec
/Users/ash/src/gitlab/gitlab-shell/spec/gitlab_shell_custom_git_receive_pack_spec.rb:5: warning: base64 was loaded from the standard library, but is not part of the default gems starting from Ruby 3.4.0.
You can add base64 to your Gemfile or gemspec to silence this warning.
An error occurred while loading ./spec/gitlab_shell_custom_git_receive_pack_spec.rb. - Did you mean?
rspec ./spec/gitlab_shell_custom_git_upload_pack_spec.rb
Failure/Error: require 'base64'
LoadError:
cannot load such file -- base64
# ./spec/gitlab_shell_custom_git_receive_pack_spec.rb:5:in '<top (required)>'
An error occurred while loading ./spec/gitlab_shell_custom_git_upload_pack_spec.rb. - Did you mean?
rspec ./spec/gitlab_shell_custom_git_receive_pack_spec.rb
Failure/Error: require 'base64'
LoadError:
cannot load such file -- base64
# ./spec/gitlab_shell_custom_git_upload_pack_spec.rb:5:in '<top (required)>'
Run options: include {focus: true}
All examples were filtered out; ignoring {focus: true}
Finished in 0.00002 seconds (files took 0.09576 seconds to load)
0 examples, 0 failures, 2 errors occurred outside of examples
make: *** [test_ruby] Error 1
With the following being the root cause:
/Users/ash/src/gitlab/gitlab-shell/spec/gitlab_shell_custom_git_receive_pack_spec.rb:5: warning: base64 was loaded from the standard library, but is not part of the default gems starting from Ruby 3.4.0.
Proposal
Add gem 'base64', '~> 0.2.0' to the group :development, :test section of the Gemfile.
Edited by Ash McKenzie