<commit_before>require 'spec_helper'

describe BooksController, 'before_action hooks' do
  before do
    Book.delete_all
    @book = Book.create! title: 'Head First ActionArgs'
    get :show, id: @book.id
  end

  context 'via Symbol' do
    subject { assigns :book }
    it { should == @book }
  end

  context 'via String' do
    subject { assigns :string_filter_executed }
    it { should be_true }
  end

  context 'via Proc' do
    subject { assigns :proc_filter_executed }
    it { should be_true }
  end
end
<commit_msg>I said, lets's make sure that around_action is working<commit_after>require 'spec_helper'

describe BooksController, 'action hooks' do
  before do
    Book.delete_all
    @book = Book.create! title: 'Head First ActionArgs'
    get :show, id: @book.id
  end

  describe 'before_action' do
    context 'via Symbol' do
      subject { assigns :book }
      it { should == @book }
    end

    context 'via String' do
      subject { assigns :string_filter_executed }
      it { should be_true }
    end

    context 'via Proc' do
      subject { assigns :proc_filter_executed }
      it { should be_true }
    end
  end

  describe 'around_action' do
    subject { assigns :elapsed_time }
    it { should be }
  end
end

{'fraction_non_alphanumeric': 0.08118971061093247, 'fraction_numerical': 0.0, 'mean_word_length': 2.8425925925925926, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '1185263', 'n_tokens_mistral': 406, 'n_tokens_neox': 386, 'n_words': 132}