<commit_before>require 'rails_helper'

RSpec.describe ApplicationHelper, :type => :helper do
  describe "#user_image" do
    it "should generate an image link" do
      user = instance_double("User", :image => 'image')
      expect(helper.user_image(user)).to eql("<img alt=\"Image\" class=\"profile-img\" src=\"/images/image\" />")
    end
  end
end<commit_msg>Better user_image test<commit_after>require 'rails_helper'

RSpec.describe ApplicationHelper, :type => :helper do
  describe "#user_image" do
    it "should generate an image link" do
      user = instance_double("User", :image => 'image_url')
      image = helper.user_image(user)
      expect(image).to have_selector(:css, "img")
      expect(image).to match("image_url")
    end
  end
end
{'fraction_non_alphanumeric': 0.1394422310756972, 'fraction_numerical': 0.0, 'mean_word_length': 4.094594594594595, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5549993', 'n_tokens_mistral': 235, 'n_tokens_neox': 229, 'n_words': 61}