Sha256: 83fa009f83bc3bcb651769ed725f45fc3c2353458eb925ba58c36fbd51f331df
Contents?: true
Size: 476 Bytes
Versions: 5
Compression:
Stored size: 476 Bytes
Contents
# frozen_string_literal: true require 'spec_helper' describe SuggestController do routes { Blacklight::Engine.routes } describe 'GET index' do it 'returns JSON' do get :index, format: 'json' expect(response.body).to eq [].to_json end it 'returns suggestions' do get :index, format: 'json', q: 'new' json = JSON.parse(response.body) expect(json.count).to eq 3 expect(json.first['term']).to eq 'new jersey' end end end
Version data entries
5 entries across 5 versions & 1 rubygems