Add Admin changes to create Poll:Questions with votation type

This commit is contained in:
lalo
2019-05-29 17:57:20 +02:00
committed by Javi Martín
parent 7c9c50f4c6
commit 23d36835d7
16 changed files with 485 additions and 16 deletions

View File

@@ -248,14 +248,17 @@ describe "Admin polls" do
scenario "Question list", :js do
poll = create(:poll)
question = create(:poll_question, poll: poll)
votation_type_question = create(:poll_question_unique, poll: poll)
other_question = create(:poll_question)
visit admin_poll_path(poll)
expect(page).to have_content "Questions (1)"
expect(page).to have_content "Questions (2)"
expect(page).to have_content question.title
expect(page).to have_content votation_type_question.title
expect(page).not_to have_content other_question.title
expect(page).not_to have_content "There are no questions assigned to this poll"
end
end