diff --git a/spec/services/item_create_service_spec.rb b/spec/services/item_create_service_spec.rb index 77ca888596..8e4e70617c 100644 --- a/spec/services/item_create_service_spec.rb +++ b/spec/services/item_create_service_spec.rb @@ -27,7 +27,7 @@ end context 'when there are no issues' do - it 'should return a success monad with success? evaluating to true and the item' do + it 'should return a success monad with success? returning true and the item' do expect(subject).to be_a_kind_of(ItemCreateService::Success) expect(subject.success?).to eq(true) expect(subject.item).to eq(fake_organization_item) @@ -48,7 +48,7 @@ allow(Organization).to receive(:find).with(organization_id).and_raise(ActiveRecord::RecordNotFound) end - it 'should return a OpenStruct with an ActiveRecord::RecordNotFound error' do + it 'should return a failure monad with an ActiveRecord::RecordNotFound error' do expect(subject).to be_a_kind_of(ItemCreateService::Failure) expect(subject.success?).to eq(false) expect(subject.error).to be_a_kind_of(ActiveRecord::RecordNotFound) @@ -62,7 +62,7 @@ allow(fake_organization_item).to receive(:save!).and_raise(fake_error) end - it 'should return a OpenStruct with the raised error' do + it 'should return a failure monad with the raised error' do expect(subject).to be_a_kind_of(ItemCreateService::Failure) expect(subject.success?).to eq(false) expect(subject.error).to eq(fake_error) diff --git a/spec/services/transfer_destroy_service_spec.rb b/spec/services/transfer_destroy_service_spec.rb index 18a59bfb9d..8906da7a72 100644 --- a/spec/services/transfer_destroy_service_spec.rb +++ b/spec/services/transfer_destroy_service_spec.rb @@ -33,7 +33,7 @@ end context 'when there are no issues' do - it 'should return a success monad with success? evaluating to true' do + it 'should return a success monad with success? returning true' do expect { subject }.to change { TransferDestroyEvent.count }.by(1) expect(subject).to be_a_kind_of(TransferDestroyService::Success) expect(subject.success?).to eq(true)