TokiTranslate/spec/requests/root_spec.rb

21 lines
517 B
Ruby

require 'rails_helper'
RSpec.describe "Root path", type: :request do
describe "GET /" do
it "works! (now write some real specs)" do
get root_path
expect(response).to have_http_status(200)
end
it "should have a link to the dictionary" do
get root_path
expect(response.body).to have_selector(%(a[href="#{dictionary_index_path}"]))
end
end
it "should have a language drop-down" do
get root_path
expect(response.body).to have_field("active_language_id")
end
end