unable to build w/o specifying rails version in ENV
Opened this issue · 0 comments
Kallin commented
This issue is a (choose one):
- [X ] Problem/bug report.
- Feature request.
- Request for support. Note: Please try to avoid submitting issues for support requests. Use Gitter instead.
Checklist before submitting:
- [ X] I've searched for an existing issue.
- [ X] I've asked my question on Gitter and have not received a satisfactory answer.
- [ N/A] I've included a complete bug report template. This step helps us and allows us to see the bug without trying to reproduce the problem from your description. It helps you because you will frequently detect if it's a problem specific to your project.
- [ N/A] The feature I'm asking for is compliant with the JSON:API spec.
Description
Bug reports:
Upon checking out this project you cannot successfully run the test suite following the instructions in the README.
running bundle install
at this moment will resolve railties-7.1.1
as a dependency. this will cause
jsonapi-resources/test/test_helper.rb
Line 26 in 0ba80a1
/Users/knagelberg/.asdf/installs/ruby/3.2.0/lib/ruby/gems/3.2.0/gems/railties-7.1.1/lib/rails.rb:51:in `configuration': undefined method `config' for nil:NilClass (NoMethodError)
application.config
^^^^^^^
from /Users/knagelberg/.asdf/installs/ruby/3.2.0/lib/ruby/gems/3.2.0/gems/railties-7.1.1/lib/rails/testing/maintain_test_schema.rb:11:in `<top (required)>'
from <internal:/Users/knagelberg/.asdf/installs/ruby/3.2.0/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from <internal:/Users/knagelberg/.asdf/installs/ruby/3.2.0/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from /Users/knagelberg/.asdf/installs/ruby/3.2.0/lib/ruby/gems/3.2.0/gems/railties-7.1.1/lib/rails/test_help.rb:17:in `<top (required)>'
from <internal:/Users/knagelberg/.asdf/installs/ruby/3.2.0/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from <internal:/Users/knagelberg/.asdf/installs/ruby/3.2.0/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
from /Users/knagelberg/codes/jsonapi-resources/test/test_helper.rb:26:in `<top (required)>'
setting RAILS_VERSION as suggested in the project:
export RAILS_VERSION=6.1.1; bundle update; bundle exec rake test
solves this problem. perhaps adjusting
Line 26 in 864e810