Fix RSpec/ContextWording cop (#24739)
This commit is contained in:
parent
cf18cc2891
commit
710745e16b
105 changed files with 559 additions and 668 deletions
|
@ -19,7 +19,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
let(:account_ids) { [Fabricate(:account).id] }
|
||||
let(:default_map) { { 1 => true } }
|
||||
|
||||
context 'options are not set' do
|
||||
context 'when options are not set' do
|
||||
let(:options) { {} }
|
||||
|
||||
it 'sets default maps' do
|
||||
|
@ -32,7 +32,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
end
|
||||
end
|
||||
|
||||
context 'options[:following_map] is set' do
|
||||
context 'when options[:following_map] is set' do
|
||||
let(:options) { { following_map: { 2 => true } } }
|
||||
|
||||
it 'sets @following merged with default_map and options[:following_map]' do
|
||||
|
@ -40,7 +40,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
end
|
||||
end
|
||||
|
||||
context 'options[:followed_by_map] is set' do
|
||||
context 'when options[:followed_by_map] is set' do
|
||||
let(:options) { { followed_by_map: { 3 => true } } }
|
||||
|
||||
it 'sets @followed_by merged with default_map and options[:followed_by_map]' do
|
||||
|
@ -48,7 +48,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
end
|
||||
end
|
||||
|
||||
context 'options[:blocking_map] is set' do
|
||||
context 'when options[:blocking_map] is set' do
|
||||
let(:options) { { blocking_map: { 4 => true } } }
|
||||
|
||||
it 'sets @blocking merged with default_map and options[:blocking_map]' do
|
||||
|
@ -56,7 +56,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
end
|
||||
end
|
||||
|
||||
context 'options[:muting_map] is set' do
|
||||
context 'when options[:muting_map] is set' do
|
||||
let(:options) { { muting_map: { 5 => true } } }
|
||||
|
||||
it 'sets @muting merged with default_map and options[:muting_map]' do
|
||||
|
@ -64,7 +64,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
end
|
||||
end
|
||||
|
||||
context 'options[:requested_map] is set' do
|
||||
context 'when options[:requested_map] is set' do
|
||||
let(:options) { { requested_map: { 6 => true } } }
|
||||
|
||||
it 'sets @requested merged with default_map and options[:requested_map]' do
|
||||
|
@ -72,7 +72,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
end
|
||||
end
|
||||
|
||||
context 'options[:requested_by_map] is set' do
|
||||
context 'when options[:requested_by_map] is set' do
|
||||
let(:options) { { requested_by_map: { 6 => true } } }
|
||||
|
||||
it 'sets @requested merged with default_map and options[:requested_by_map]' do
|
||||
|
@ -80,7 +80,7 @@ RSpec.describe AccountRelationshipsPresenter do
|
|||
end
|
||||
end
|
||||
|
||||
context 'options[:domain_blocking_map] is set' do
|
||||
context 'when options[:domain_blocking_map] is set' do
|
||||
let(:options) { { domain_blocking_map: { 7 => true } } }
|
||||
|
||||
it 'sets @domain_blocking merged with default_map and options[:domain_blocking_map]' do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue