diff options
author | Jasper Maes <jaspermaes.jm@gmail.com> | 2019-01-16 00:05:36 +0300 |
---|---|---|
committer | Heinrich Lee Yu <heinrich@gitlab.com> | 2019-04-23 03:31:23 +0300 |
commit | 624a1cdab4da67c7b363602aa1178d0e6ff63475 (patch) | |
tree | 09892175f885c4c5f6725314b25a61280395efcb /spec/services/users | |
parent | 46bdbc5d776a0438366426e0ef48911123311744 (diff) |
Upgrade Rails to 5.1.6.1
Model.new.attributes now also returns encrypted attributes.
Diffstat (limited to 'spec/services/users')
-rw-r--r-- | spec/services/users/destroy_service_spec.rb | 4 | ||||
-rw-r--r-- | spec/services/users/migrate_to_ghost_user_service_spec.rb | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/spec/services/users/destroy_service_spec.rb b/spec/services/users/destroy_service_spec.rb index 1c79af34538..4a5f4509a7b 100644 --- a/spec/services/users/destroy_service_spec.rb +++ b/spec/services/users/destroy_service_spec.rb @@ -210,6 +210,8 @@ describe Users::DestroyService do describe "calls the before/after callbacks" do it 'of project_members' do + expect_any_instance_of(ProjectMember).to receive(:run_callbacks).with(:find).once + expect_any_instance_of(ProjectMember).to receive(:run_callbacks).with(:initialize).once expect_any_instance_of(ProjectMember).to receive(:run_callbacks).with(:destroy).once service.execute(user) @@ -219,6 +221,8 @@ describe Users::DestroyService do group_member = create(:group_member) group_member.group.group_members.create(user: user, access_level: 40) + expect_any_instance_of(GroupMember).to receive(:run_callbacks).with(:find).once + expect_any_instance_of(GroupMember).to receive(:run_callbacks).with(:initialize).once expect_any_instance_of(GroupMember).to receive(:run_callbacks).with(:destroy).once service.execute(user) diff --git a/spec/services/users/migrate_to_ghost_user_service_spec.rb b/spec/services/users/migrate_to_ghost_user_service_spec.rb index b808fa6d91a..40206775aed 100644 --- a/spec/services/users/migrate_to_ghost_user_service_spec.rb +++ b/spec/services/users/migrate_to_ghost_user_service_spec.rb @@ -80,7 +80,7 @@ describe Users::MigrateToGhostUserService do context "when record migration fails with a rollback exception" do before do - expect_any_instance_of(MergeRequest::ActiveRecord_Associations_CollectionProxy) + expect_any_instance_of(ActiveRecord::Associations::CollectionProxy) .to receive(:update_all).and_raise(ActiveRecord::Rollback) end |