<commit_before>require "spec_helper"

describe Onebox::Engine::ItunesOnebox do
  before(:all) do
    @link = "https://itunes.apple.com/us/app/minecraft-pocket-edition/id479516143?mt=8"
    fake(@link, response("itunes"))
  end
  before(:each) { Onebox.defaults.cache.clear }

  let(:link) { @link }

  it_behaves_like "an engine"

  describe "#to_html" do
    let(:html) { described_class.new(link).to_html }

    it "returns the product title" do
      expect(html).to include("Minecraft – Pocket Edition")
    end

    it "returns the product image" do
      expect(html).to include("bxerxqln.png")
    end

    it "returns the product description" do
      expect(html).to include("Get Minecraft – Pocket Edition on the App Store.")
    end
  end
end
<commit_msg>edit itunes onebox spec to conform to standard spec format<commit_after>require "spec_helper"

describe Onebox::Engine::ItunesOnebox do
  before(:all) do
    @link = "https://itunes.apple.com/us/app/minecraft-pocket-edition/id479516143?mt=8"
    fake(@link, response(described_class.template_name))
  end
  before(:each) { Onebox.defaults.cache.clear }

  let(:link) { @link }

  it_behaves_like "an engine"

  describe "#to_html" do
    let(:html) { described_class.new(link).to_html }

    it "returns the product title" do
      expect(html).to include("Minecraft – Pocket Edition")
    end

    it "returns the product image" do
      expect(html).to include("bxerxqln.png")
    end

    it "returns the product description" do
      expect(html).to include("Get Minecraft – Pocket Edition on the App Store.")
    end
  end
end

{'fraction_non_alphanumeric': 0.1195244055068836, 'fraction_numerical': 0.012515644555694618, 'mean_word_length': 3.6618075801749272, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, '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': '3097130', 'n_tokens_mistral': 548, 'n_tokens_neox': 518, 'n_words': 137}