diff options
author | Stan Hu <stanhu@gmail.com> | 2015-08-24 17:46:06 +0300 |
---|---|---|
committer | Stan Hu <stanhu@gmail.com> | 2015-08-24 17:46:06 +0300 |
commit | 19f478e00d1508728d0170ac60defed0535a0789 (patch) | |
tree | 7b4c04fe079dad04a0619c03ada54f780005b1bc /spec/requests/api/groups_spec.rb | |
parent | 24b282aeeaf5ba41c6b73100051eb48428787770 (diff) |
Fix Error 500 in API when accessing a group that has an avatar
Closes #2340
Diffstat (limited to 'spec/requests/api/groups_spec.rb')
-rw-r--r-- | spec/requests/api/groups_spec.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/spec/requests/api/groups_spec.rb b/spec/requests/api/groups_spec.rb index 1d5b4f6f36b..13cced81875 100644 --- a/spec/requests/api/groups_spec.rb +++ b/spec/requests/api/groups_spec.rb @@ -7,7 +7,8 @@ describe API::API, api: true do let(:user2) { create(:user) } let(:user3) { create(:user) } let(:admin) { create(:admin) } - let!(:group1) { create(:group) } + let(:avatar_file_path) { File.join(Rails.root, 'spec', 'fixtures', 'banana_sample.gif') } + let!(:group1) { create(:group, avatar: File.open(avatar_file_path)) } let!(:group2) { create(:group) } before do |