DEV: Fix randomly failing spec.

If a user is created with an id of 999, a `upload.user_id ==
user_avatar.user_id` will return true. This fix increases the id of the
upload to something that we will not hit in the foreseeable future.
This commit is contained in:
Guo Xiang Tan 2020-05-21 07:19:25 +08:00
parent df68d11c38
commit f4b82f1dc0
No known key found for this signature in database
GPG Key ID: FBD110179AAC1F20
1 changed files with 2 additions and 2 deletions

View File

@ -25,13 +25,13 @@ describe UserGuardian do
end end
let :already_uploaded do let :already_uploaded do
u = Upload.new(user_id: 999, id: 2) u = Upload.new(user_id: 9999, id: 2)
user_avatar.custom_upload_id = u.id user_avatar.custom_upload_id = u.id
u u
end end
let :not_my_upload do let :not_my_upload do
Upload.new(user_id: 999, id: 3) Upload.new(user_id: 9999, id: 3)
end end
let(:moderator_upload) do let(:moderator_upload) do