<commit_before>require 'spec_helper'

describe Spree::ContentController do
  before :each do
    controller.stub :current_user => create(:user)
  end

  it "fires event for #show" do
    # we are using cvv because the file exists in core/views/content
    controller.should_receive(:fire_event).
               with('spree.content.visited', hash_including(:path => "content/cvv"))
    get :show, :path => "cvv"
 end

  it "fires event for content actions like #cvv" do
    controller.should_receive(:fire_event).
               with('spree.content.visited', hash_including(:path => "content/cvv"))
    get :cvv
  end

end<commit_msg>[promo] Use correct action helpers in spree/content_controller_spec<commit_after>require 'spec_helper'

describe Spree::ContentController do
  before :each do
    controller.stub :current_user => create(:user)
  end

  it "fires event for #show" do
    # we are using cvv because the file exists in core/views/content
    controller.should_receive(:fire_event).
               with('spree.content.visited', hash_including(:path => "content/cvv"))
    spree_get :show, :path => "cvv"
 end

  it "fires event for content actions like #cvv" do
    controller.should_receive(:fire_event).
               with('spree.content.visited', hash_including(:path => "content/cvv"))
    spree_get :cvv
  end

end

{'fraction_non_alphanumeric': 0.11027756939234809, 'fraction_numerical': 0.0, 'mean_word_length': 3.615916955017301, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 11, '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': '4888855', 'n_tokens_mistral': 417, 'n_tokens_neox': 403, 'n_words': 113}