Explicitly requiring rspec/core and rspec/matchers on the RSpec helper to ensure the libraries have been loaded before the helper code is run. Fix #261
This commit is contained in:
parent
fdf85343a8
commit
94f1155286
|
@ -3,13 +3,14 @@
|
||||||
- [#224](https://github.com/airblade/paper_trail/issues/224)/[#236](https://github.com/airblade/paper_trail/pull/236) -
|
- [#224](https://github.com/airblade/paper_trail/issues/224)/[#236](https://github.com/airblade/paper_trail/pull/236) -
|
||||||
Fixed compatibility with [ActsAsTaggableOn](https://github.com/mbleigh/acts-as-taggable-on).
|
Fixed compatibility with [ActsAsTaggableOn](https://github.com/mbleigh/acts-as-taggable-on).
|
||||||
- [#235](https://github.com/airblade/paper_trail/pull/235) - Dropped unnecessary secondary sort on `versions` association.
|
- [#235](https://github.com/airblade/paper_trail/pull/235) - Dropped unnecessary secondary sort on `versions` association.
|
||||||
|
- [#216](https://github.com/airblade/paper_trail/pull/216) - Added helper & extension for [RSpec](https://github.com/rspec/rspec),
|
||||||
|
and helper for [Cucumber](http://cukes.info).
|
||||||
- [#212](https://github.com/airblade/paper_trail/pull/212) - Added `PaperTrail::Cleaner` module, useful for discarding draft versions.
|
- [#212](https://github.com/airblade/paper_trail/pull/212) - Added `PaperTrail::Cleaner` module, useful for discarding draft versions.
|
||||||
- [#207](https://github.com/airblade/paper_trail/issues/207) - Versions for `'create'` events are now created with `create!` instead of
|
- [#207](https://github.com/airblade/paper_trail/issues/207) - Versions for `'create'` events are now created with `create!` instead of
|
||||||
`create` so that an exception gets raised if it is appropriate to do so.
|
`create` so that an exception gets raised if it is appropriate to do so.
|
||||||
- [#199](https://github.com/airblade/paper_trail/pull/199) - Rails 4 compatibility.
|
- [#199](https://github.com/airblade/paper_trail/pull/199) - Rails 4 compatibility.
|
||||||
- [#165](https://github.com/airblade/paper_trail/pull/165) - Namespaced the version class under the `PaperTrail` module.
|
- [#165](https://github.com/airblade/paper_trail/pull/165) - Namespaced the version class under the `PaperTrail` module.
|
||||||
- [#119](https://github.com/airblade/paper_trail/issues/119) - Support for [Sinatra](http://www.sinatrarb.com/); decoupled gem from `Rails`.
|
- [#119](https://github.com/airblade/paper_trail/issues/119) - Support for [Sinatra](http://www.sinatrarb.com/); decoupled gem from `Rails`.
|
||||||
|
|
||||||
|
|
||||||
## 2.7.2
|
## 2.7.2
|
||||||
|
|
||||||
|
|
|
@ -845,7 +845,7 @@ You may want to turn PaperTrail off to speed up your tests. See the [Turning Pa
|
||||||
|
|
||||||
PaperTrail provides a helper that works with RSpec to make it easier to control when `PaperTrail` during testing. By default, PaperTrail will be
|
PaperTrail provides a helper that works with RSpec to make it easier to control when `PaperTrail` during testing. By default, PaperTrail will be
|
||||||
turned off for all tests. When you wish to enable PaperTrail for a test you can either wrap the test in a `with_versioning` block, or pass
|
turned off for all tests. When you wish to enable PaperTrail for a test you can either wrap the test in a `with_versioning` block, or pass
|
||||||
in `:versioning => true` option to a test block, like so:
|
in `:versioning => true` option to a spec block, like so:
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
describe "RSpec test group" do
|
describe "RSpec test group" do
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
if defined? RSpec
|
if defined? RSpec
|
||||||
|
require 'rspec/core'
|
||||||
|
require 'rspec/matchers'
|
||||||
require File.expand_path('../rspec/extensions', __FILE__)
|
require File.expand_path('../rspec/extensions', __FILE__)
|
||||||
|
|
||||||
RSpec.configure do |config|
|
RSpec.configure do |config|
|
||||||
|
|
Loading…
Reference in New Issue