Order dependant spec failure in ee/spec/services/projects/update_mirror_service_spec.rb
As seen in: https://gitlab.com/gitlab-org/gitlab-ee/-/jobs/87317361, https://gitlab.com/gitlab-org/gitlab-ee/-/jobs/87325721 https://gitlab.com/gitlab-org/gitlab-ee/-/jobs/87338283
Failures:
1) Projects::UpdateMirrorService#execute when the mirror user doesn't have access fails
Failure/Error: @user.update_attribute(:last_activity_on, Date.today)
RuntimeError:
stubbed models are not allowed to access the database - User#update_attribute(last_activity_on,2018-08-07)
# ./app/services/users/activity_service.rb:33:in `record_activity'
# ./app/services/users/activity_service.rb:21:in `execute'
# ./app/services/event_create_service.rb:92:in `push'
# ./app/services/git_tag_push_service.rb:12:in `execute'
# ./ee/app/services/projects/update_mirror_service.rb:89:in `block in update_tags'
# ./ee/app/services/projects/update_mirror_service.rb:73:in `each'
# ./ee/app/services/projects/update_mirror_service.rb:73:in `update_tags'
# ./ee/app/services/projects/update_mirror_service.rb:15:in `execute'
# ./ee/spec/services/projects/update_mirror_service_spec.rb:201:in `block (4 levels) in <top (required)>'
Finished in 25 minutes 6 seconds (files took 20.2 seconds to load)
2551 examples, 1 failure, 1 pending
Failed examples:
rspec ./ee/spec/services/projects/update_mirror_service_spec.rb:198 # Projects::UpdateMirrorService#execute when the mirror user doesn't have access fails
This might be related to https://gitlab.com/gitlab-org/gitlab-ee/issues/5275