-
-
Notifications
You must be signed in to change notification settings - Fork 41
Add initial draft of 3.8 blog post. #115
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
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,112 @@ | ||
--- | ||
title: RSpec 3.8 has been released! | ||
author: Myron Marston | ||
--- | ||
|
||
RSpec 3.8 has just been released! Given our commitment to | ||
[semantic versioning](http://semver.org/), this should be an easy | ||
upgrade for anyone already using RSpec 3, but if we did introduce | ||
any regressions, please let us know, and we'll get a patch release | ||
out with a fix ASAP. | ||
|
||
We're also happy to announce that [Benoit Tigeot](https://github.com/benoittgt) | ||
has joined the RSpec team since the last release. Welcome to the team, Benoit! | ||
We know you'll do great things :). | ||
|
||
RSpec continues to be a community-driven project with contributors | ||
from all over the world. This release includes over xxx commits and yyy | ||
merged pull requests from zzz different contributors! | ||
|
||
Thank you to everyone who helped make this release happen! | ||
|
||
## Notable Changes | ||
|
||
### Core: Performance of --bisect has been significantly improved | ||
|
||
RSpec has supported a `--bisect` feature since | ||
[RSpec 3.3](/blog/2015/06/rspec-3-3-has-been-released/#core-bisect). | ||
This feature is useful when your test suite has an ordering | ||
dependency--that is, the suite only fails when the tests are run | ||
in a specific order. `--bisect` will repeatedly run smaller and | ||
smaller subsets of your suite in order to narrow it down to the | ||
minimal set of specs needed to reproduce the failures. | ||
|
||
Since 3.3, this feature has been implemented by shelling out to | ||
the `rspec` command to run each subset. While simple and effective, | ||
we realized this approach was also quite inefficient. Each time the | ||
`rspec` command runs, it must boot RSpec and your application | ||
environment (which may include Rails and many other gems) from scratch. | ||
The cost of this can vary considerably from a couple hundred milliseconds | ||
to 30+ seconds on a large Rails app. In extreme cases, the runtime of | ||
`--bisect` can be dominated by the time it takes to boot your application | ||
environment over and over and over. | ||
|
||
In RSpec 3.8, we've improved bisect's performance by using forking | ||
on platforms that support it rather than shelling out. That way, we | ||
can boot your application environment _once_, and then fork a subprocess | ||
in which to run each subset of the test suite, avoiding the need to boot | ||
your application many times. | ||
|
||
The actual improvement you'll see in practice will vary widely, but | ||
in our [limited testing](https://github.com/rspec/rspec-core/pull/2511) | ||
it improved the runtime of `--bisect` by 33% in one case and an | ||
order-of-magnitude (108.9 seconds down to 11.7 seconds) in another. | ||
|
||
If you're looking to maximize the benefit of this change, you may | ||
want to pass some additional `--require` options when running a | ||
bisection in order to pre-load as much of your application environment | ||
as possible. | ||
|
||
### Core: Support the XDG base directory spec for configuration | ||
|
||
RSpec, like many command line tools, supports the use of options | ||
files, which can live at `.rspec` (for team project options) | ||
`~/.rspec` (for global personal options) or at `.rspec-local` | ||
(for personal project options -- this file should not be under | ||
source control). In RSpec 3.8, we've expanded this feature to | ||
support the [XDG Base Directory | ||
Specification](https://specifications.freedesktop.org/basedir-spec/latest/), | ||
which defines a standard way for tools to locate the global personal | ||
options file. This gives users complete control over where this | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Double spacing typo here? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Old habit of mine. Fixed. |
||
file is located rather than forcing it to live in their home directory. | ||
|
||
To use this feature, simply set the `$XDG_CONFIG_HOME` environment | ||
variable and put your RSpec options at `$XDG_CONFIG_HOME/rspec/options`. | ||
|
||
For more info, [read the spec](https://specifications.freedesktop.org/basedir-spec/latest/) | ||
or [check out the pull | ||
request](https://github.com/rspec/rspec-core/pull/2538). | ||
|
||
Thanks to Magnus Bergmark for implementing this feature! | ||
|
||
### Expectations: Formatted output length is now configurable | ||
|
||
TODO (Sam/Benoit): write this up since you authored this feature | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How about:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks, I've adapted this. |
||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. That doesn't seem all that notable, to be honest. If it's not important enough to describe, we shouldn't mention it, I don't think. It's in the changelog. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I wanted to highlight this as I feel documentation / usability tweaks are important, it was more of a "shout out" than "notable". |
||
### Rails: ? | ||
|
||
TODO (Sam/Benoit/Jon): figure out what is notable | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks, I've added these, except for the last one. It's not clear what qualifies as a "longer namespace." Is it one over 10 characters? 20? 30? And also it doesn't seem that notable--it's just a bug fix, right? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Its any multi part namespace over 2, I'm on the fence about it but similar to the other questionable one, it was more about highlighting contributor effort. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Contributor effort has never been the basis on whether or not we highlight something as notable in our release blog post. It's about the effect the change has for users of RSpec. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fair enough, how do you feel, given that our contributor count is quite low at the moment, about simply listing everyone who helped on this release at the end of the blog post? A "And thanks to who helped with this release". There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. All contributors will be listed in "Stats" section (example). And they're also listed in the changelog for their individual contributions. We don't need to list all the contributors 3 times in the same blog post. |
||
|
||
## Stats: | ||
|
||
TODO: generate | ||
|
||
## Docs | ||
|
||
### API Docs | ||
|
||
* [rspec-core](/documentation/3.8/rspec-core/) | ||
* [rspec-expectations](/documentation/3.8/rspec-expectations/) | ||
* [rspec-mocks](/documentation/3.8/rspec-mocks/) | ||
* [rspec-rails](/documentation/3.8/rspec-rails/) | ||
|
||
### Cucumber Features | ||
|
||
* [rspec-core](http://relishapp.com/rspec/rspec-core) | ||
* [rspec-expectations](http://relishapp.com/rspec/rspec-expectations) | ||
* [rspec-mocks](http://relishapp.com/rspec/rspec-mocks) | ||
* [rspec-rails](http://relishapp.com/rspec/rspec-rails) | ||
|
||
## Release notes: | ||
|
||
TODO: generate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Double spacing typo here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed.