Sha256: 380ffb2e1181966dab5e5b633f53426432dc6339070869abb62f50f677c3936f

Contents?: true

Size: 563 Bytes

Versions: 5

Compression:

Stored size: 563 Bytes

Contents

require "spec_helper.rb"

describe "ndl_books/index" do
  describe "ndl search menu" do
    it "should reflect query params for views", vcr: true do
      params[:query] = "test"
      assign(:query, "test")
      books = NdlBook.search(params[:query])
      assign(:books, Kaminari.paginate_array(books[:items],
                                             total_count: books[:total_entries],
                                             ).page(1).per(10))
      render
      expect(rendered).to include "https://iss.ndl.go.jp/books?any=test"
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
enju_ndl-0.3.3 spec/views/ndl_books/index.html.erb_spec.rb
enju_ndl-0.3.2 spec/views/ndl_books/index.html.erb_spec.rb
enju_ndl-0.4.0.rc.1 spec/views/ndl_books/index.html.erb_spec.rb
enju_ndl-0.4.0.beta.1 spec/views/ndl_books/index.html.erb_spec.rb
enju_ndl-0.3.1 spec/views/ndl_books/index.html.erb_spec.rb