Skip to content

Commit ce35994

Browse files
committed
Update to RSpec 4-compatible syntax
1 parent 7d76c75 commit ce35994

2 files changed

Lines changed: 1 addition & 46 deletions

File tree

.rspec

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
--color
21
--require spec_helper

spec/spec_helper.rb

Lines changed: 1 addition & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -7,51 +7,7 @@
77

88
# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
99
RSpec.configure do |config|
10-
config.expect_with :rspec do |expectations|
11-
# This option will default to `true` in RSpec 4. It makes the `description`
12-
# and `failure_message` of custom matchers include text for helper methods
13-
# defined using `chain`, e.g.:
14-
# be_bigger_than(2).and_smaller_than(4).description
15-
# # => "be bigger than 2 and smaller than 4"
16-
# ...rather than:
17-
# # => "be bigger than 2"
18-
expectations.include_chain_clauses_in_custom_matcher_descriptions = true
19-
end
20-
21-
config.mock_with :rspec do |mocks|
22-
# Prevents you from mocking or stubbing a method that does not exist on
23-
# a real object. This is generally recommended, and will default to
24-
# `true` in RSpec 4.
25-
mocks.verify_partial_doubles = true
26-
end
27-
28-
# These two settings work together to allow you to limit a spec run
29-
# to individual examples or groups you care about by tagging them with
30-
# `:focus` metadata. When nothing is tagged with `:focus`, all examples
31-
# get run.
32-
config.filter_run :focus
33-
config.run_all_when_everything_filtered = true
34-
35-
# Limits the available syntax to the non-monkey patched syntax that is
36-
# recommended. For more details, see:
37-
# - http://myronmars.to/n/dev-blog/2012/06/rspecs-new-expectation-syntax
38-
# - http://teaisaweso.me/blog/2013/05/27/rspecs-new-message-expectation-syntax/
39-
# - http://myronmars.to/n/dev-blog/2014/05/notable-changes-in-rspec-3#new__config_option_to_disable_rspeccore_monkey_patching
40-
config.disable_monkey_patching!
41-
42-
# This setting enables warnings. It's recommended, but in some cases may
43-
# be too noisy due to issues in dependencies.
44-
config.warnings = true
45-
46-
# Many RSpec users commonly either run the entire suite or an individual
47-
# file, and it's useful to allow more verbose output when running an
48-
# individual spec file.
49-
if config.files_to_run.one?
50-
# Use the documentation formatter for detailed output,
51-
# unless a formatter has already been configured
52-
# (e.g. via a command-line flag).
53-
config.default_formatter = "doc"
54-
end
10+
config.warnings = :all
5511

5612
# Print the 10 slowest examples and example groups at the
5713
# end of the spec run, to help surface which specs are running

0 commit comments

Comments
 (0)