title: rspec expect symbol not equal to created object
body: <p>I wrote a test for controll with rspec: </p>
  
  <pre><code>it "populates an array of books" do
    book = FactoryGirl.create(:book)
    get :index
    expect(:books).to eql([book])
  end
  </code></pre>
  
  <p>books_controller.rb</p>
  
  <pre><code>def index
    @books = Book.all.order("created_at DESC")   
  end
  </code></pre>
  
  <p>books.rb</p>
  
  <pre><code>FactoryGirl.define do
    factory :book do |f|
      f.name { Faker::Book.title }
      f.author { Faker::Book.author }
      f.press { Faker::Book.publisher }
      f.cover { fixture_file_upload(Rails.root.join('spec', 'photos', 'testcover.jpg'), 'image/png') }
    end
  end
  </code></pre>
  
  <p>Run bin/rake spec, the result is:</p>
  
  <pre><code>1) BooksController GET #index populates an array of books
   Failure/Error: expect(:books).to eql([book])
  
     expected: [#&lt;Book id: 1, name: "The Waste Land", author: "谢靖琪", isbn: nil, press: "University of Chicago Press"...e: "image/png", cover_file_size: 104531, cover_updated_at: "2016-08-26 04:00:19", page_number: nil&gt;]
          got: :books
  
     (compared using eql?)
  
     Diff:
     @@ -1,2 +1,2 @@
     -[#&lt;Book id: 1, name: "The Waste Land", author: "谢靖琪", isbn: nil, press: "University of Chicago Press", description: nil, grade_level: nil, lexile_level: nil, douban_link: nil, scholastic_link: nil, created_at: "2016-08-26 04:00:19", updated_at: "2016-08-26 04:00:19", cover_file_name: "fcbcb7417dbc88827d16765a.jpg", cover_content_type: "image/png", cover_file_size: 104531, cover_updated_at: "2016-08-26 04:00:19", page_number: nil&gt;]
     +:books
  </code></pre>
  
  <p>They are not equal. It seems that the first expected result, '...' is an abbreviation. How can I fix it? </p>