diff options
author | Jan-Gerd Tenberge <janten@gmail.com> | 2015-10-22 22:43:17 +0300 |
---|---|---|
committer | Jan-Gerd Tenberge <janten@gmail.com> | 2015-10-22 22:43:17 +0300 |
commit | b5c19bcc4d02fd498bc95d70c39bd88ec9cdda4b (patch) | |
tree | 6eaed47ca3b65dbd622813497b18902666d23d68 /spec/helpers/application_helper_spec.rb | |
parent | b32bb377993fb0224ed3bd9294d752d1a82b2ef9 (diff) | |
parent | a7174efaec77e9408900336b5941d9cca1f82ccf (diff) |
Fix merge error
Diffstat (limited to 'spec/helpers/application_helper_spec.rb')
-rw-r--r-- | spec/helpers/application_helper_spec.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/helpers/application_helper_spec.rb b/spec/helpers/application_helper_spec.rb index eadabb2e7b4..670be75f763 100644 --- a/spec/helpers/application_helper_spec.rb +++ b/spec/helpers/application_helper_spec.rb @@ -99,6 +99,15 @@ describe ApplicationHelper do helper.avatar_icon('foo@example.com', 20, 2) end + + describe 'using a User' do + it 'should return an URL for the avatar' do + user = create(:user, avatar: File.open(avatar_file_path)) + + expect(helper.avatar_icon(user).to_s). + to match("/uploads/user/avatar/#{user.id}/banana_sample.gif") + end + end end describe 'gravatar_icon' do |