26 lines
766 B
Ruby
26 lines
766 B
Ruby
require 'rails_helper'
|
|
|
|
RSpec.describe Public::CastingCallsController, type: :controller do
|
|
render_views
|
|
|
|
describe "#show" do
|
|
let(:casting_call) { create(:casting_call) }
|
|
|
|
it "responds successfully" do
|
|
get :show, params: { token: casting_call.token }
|
|
|
|
expect(response).to be_successful
|
|
expect(assigns(:casting_call)).to eq(casting_call)
|
|
end
|
|
|
|
it "shows casting call details" do
|
|
get :show, params: { token: casting_call.token }
|
|
|
|
expect(response.body).to have_content(casting_call.title)
|
|
expect(response.body).to have_content(casting_call.description)
|
|
expect(response.body).to have_content(casting_call.project_description)
|
|
expect(response.body).to have_link("Schedule an Audition")
|
|
end
|
|
end
|
|
end
|