Skip to content

Conversation

@pirj
Copy link
Member

@pirj pirj commented May 20, 2020

Mostly related to either RSpec Rails 3 or even earlier.

@pirj pirj self-assigned this May 20, 2020

### Install the bundle

$ bundle install
Copy link
Member Author

Choose a reason for hiding this comment

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

install is not enough as it doesn't add to Gemfile.lock.

Copy link
Member

Choose a reason for hiding this comment

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

Can you clarify? I thought bundle was short for bundle install and should be sufficient for a new app...

Copy link
Member Author

Choose a reason for hiding this comment

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

Install the gems specified in your Gemfile(5). If this is the first time you run bundle install (and a Gemfile.lock does not exist), Bundler will fetch all remote sources, resolve dependencies and install all needed gems.

You're right. I had an impression that bundle install is not supposed to create/update Gemfile.lock. It seems that it's only the case for bundle install --frozen.
Will revert this.


### Run RSpec

$ rake spec
Copy link
Member Author

Choose a reason for hiding this comment

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

Never using this, not sure if it can/should be rails spec now or rake is preferrable just like with running other common tasks.

Copy link
Member

Choose a reason for hiding this comment

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

Is rails available in 5?

Copy link
Member Author

Choose a reason for hiding this comment

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

4.2 | >= 3.1
5.0 | >= 3.5
5.1 | >= 3.6
5.2 | >= 3.8
Copy link
Member Author

Choose a reason for hiding this comment

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

It might be that Rails 5.2 was supported in 3.6/3.7, but in 3.8 there were some fixes to improve Rails 5.2 support.

Copy link
Member

Choose a reason for hiding this comment

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

👍

@@ -1,5 +1,3 @@
- upgrade:
- from_1x_to_2x.md (From rspec-rails-1.x to rspec-rails-2)
Copy link
Member Author

Choose a reason for hiding this comment

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

Ooops, leftover.

@pirj pirj requested review from JonRowe and benoittgt May 20, 2020 20:30
4.2 | >= 3.1
5.0 | >= 3.5
5.1 | >= 3.6
5.2 | >= 3.8
Copy link
Member

Choose a reason for hiding this comment

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

👍


### Run RSpec

$ rake spec
Copy link
Member

Choose a reason for hiding this comment

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

Is rails available in 5?

@pirj pirj force-pushed the drop-rails-3-docs branch from 301cf41 to 339929a Compare May 20, 2020 22:38
@pirj pirj requested a review from JonRowe May 20, 2020 22:38
@pirj pirj force-pushed the drop-rails-3-docs branch from 98e0218 to 90bff23 Compare May 21, 2020 20:37
Comment on lines 3 to 7
RSpec Rails 4 requires Ruby 2.2.

There are several changes specific to `rspec-rails` to be aware of:
Please also keep in mind that even though RSpec Rails 4 has soft support for Rails 4.2, it's recommended to use Rails 5+.

- [Default helper files created in RSpec 3.x have changed](#default-helper-files)
Other than that, there is nothing that needs to be done to upgrade from RSpec Rails 3 to version 4.0.
Copy link
Member

Choose a reason for hiding this comment

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

I would rephrase this, I feel its important to emphasise the last part, and less so the first part.

Suggested change
RSpec Rails 4 requires Ruby 2.2.
There are several changes specific to `rspec-rails` to be aware of:
Please also keep in mind that even though RSpec Rails 4 has soft support for Rails 4.2, it's recommended to use Rails 5+.
- [Default helper files created in RSpec 3.x have changed](#default-helper-files)
Other than that, there is nothing that needs to be done to upgrade from RSpec Rails 3 to version 4.0.
RSpec Rails 4 is a major version under semantic versioning, it allowed us to change the supported Rails versions to 5 and 6 only. There are no changes required to upgrade to RSpec Rails 4 if you are using Rails 5 or 6.
If you are using Rails 4.2 you can use RSpec Rails 4, but note that support for it is not maintained, we consider this a breaking change hence the version change, and you must be on Ruby 2.2 as a minimum.

Copy link
Member Author

Choose a reason for hiding this comment

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

Much better, thanks.

Mostly related to either RSpec Rails 3 or even earlier.
@pirj pirj force-pushed the drop-rails-3-docs branch from 760f6c1 to fe67624 Compare May 24, 2020 12:09
@pirj pirj requested a review from JonRowe May 24, 2020 12:09
@JonRowe JonRowe merged commit 1e8d7df into master May 24, 2020
@JonRowe JonRowe deleted the drop-rails-3-docs branch May 24, 2020 17:22
JonRowe added a commit that referenced this pull request May 24, 2020
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.

3 participants