Skip to content

Commit

Permalink
Replace should-example with expect-example
Browse files Browse the repository at this point in the history
  • Loading branch information
ngoral committed Apr 27, 2020
1 parent dff8957 commit f275bba
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/rubocop/cop/rspec/named_subject.rb
Expand Up @@ -6,7 +6,7 @@ module RSpec
# Checks for explicitly referenced test subjects.
#
# RSpec lets you declare an "implicit subject" using `subject { ... }`
# which allows for tests like `it { should be_valid }`. If you need to
# which allows for tests like `it { is_expected.to be_valid }`. If you need to
# reference your test subject you should explicitly name it using
# `subject(:your_subject_name) { ... }`. Your test subjects should be
# the most important object in your tests so they deserve a descriptive
Expand Down Expand Up @@ -39,7 +39,7 @@ module RSpec
# RSpec.describe Foo do
# subject(:user) { described_class.new }
#
# it { should be_valid }
# it { is_expected.to be_valid }
# end
class NamedSubject < Cop
MSG = 'Name your test subject if you need '\
Expand Down
2 changes: 1 addition & 1 deletion manual/cops_rspec.md
Expand Up @@ -2155,7 +2155,7 @@ end
RSpec.describe Foo do
subject(:user) { described_class.new }

it { should be_valid }
it { is_expected.to be_valid }
end
```

Expand Down

0 comments on commit f275bba

Please sign in to comment.