aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoachim Filip Ignacy Bartosik <jbartosik@gmail.com>2010-07-16 12:43:37 +0200
committerJoachim Filip Ignacy Bartosik <jbartosik@gmail.com>2010-07-29 19:49:16 +0200
commit64f31bfd600b57b99b133cbad3410dd07d64f846 (patch)
treef3602086e174da85c4c2c35f295cfd69fe808336 /features
parentNotify users trying to answer email question if question wasn't recognised (diff)
downloadrecruiting-webapp-64f31bfd600b57b99b133cbad3410dd07d64f846.tar.gz
recruiting-webapp-64f31bfd600b57b99b133cbad3410dd07d64f846.tar.bz2
recruiting-webapp-64f31bfd600b57b99b133cbad3410dd07d64f846.zip
Cover editing questions content with cucumber features
Changes needed to pass features included.
Diffstat (limited to 'features')
-rw-r--r--features/answer_text_question.feature19
-rw-r--r--features/clean_ui.feature2
-rw-r--r--features/email_answers.feature20
3 files changed, 40 insertions, 1 deletions
diff --git a/features/answer_text_question.feature b/features/answer_text_question.feature
index 7230fd9..79c8ba8 100644
--- a/features/answer_text_question.feature
+++ b/features/answer_text_question.feature
@@ -14,3 +14,22 @@ Feature: Answering text question
When I press "Create Answer"
Then I should see "The answer was created successfully" within ".flash.notice"
+
+ Scenario: Create and edit text question
+ Given I am logged in as administrator
+ When I follow "Suggestion questions"
+ And I follow "New question"
+ And I fill in "some question" for "question[title]"
+ And I press "Create Question"
+ Then I should see "The question was created successfully" within ".flash.notice"
+
+ When I follow "Add text content"
+ And I fill in "some question" for "question_content_text[content]"
+ And press "Create Question Content Text"
+ Then I should see "The question content text was created successfully" within ".flash.notice"
+
+ When I am on show "some question" question page
+ And I follow "content"
+ And I fill in "Some question." for "question_content_text[content]"
+ And press "Save"
+ Then I should see "Changes to the question content text were saved" within ".flash.notice"
diff --git a/features/clean_ui.feature b/features/clean_ui.feature
index 23ef052..c718756 100644
--- a/features/clean_ui.feature
+++ b/features/clean_ui.feature
@@ -51,7 +51,7 @@ Feature: Clean UI
And I fill in "doc" for "question[documentation]"
And I press "Create Question"
Then I should see following:
- |Add text content|Add multiple choice content|
+ |Add text content|Add multiple choice content|Add email content|
Scenario: Don't show questions with no content
Given a question "question" in category "category"
diff --git a/features/email_answers.feature b/features/email_answers.feature
index 19ef7fe..34a4a25 100644
--- a/features/email_answers.feature
+++ b/features/email_answers.feature
@@ -38,3 +38,23 @@ Feature: gentoo-dev-announce
Given recruit that should answer gentoo-dev-announce posting question
When I am on show "gentoo-dev-announce posting" question page
Then I should not see "Your answer should have subject (without quotes)"
+
+ Scenario: Create and edit email question
+ Given I am logged in as administrator
+ When I follow "Suggestion questions"
+ And I follow "New question"
+ And I fill in "some question" for "question[title]"
+ And I press "Create Question"
+ Then I should see "The question was created successfully" within ".flash.notice"
+
+ When I follow "Add email content"
+ And I fill in "some question" for "question_content_email[description]"
+ And I fill in "To : me" for "question_content_email[req_text]"
+ And press "Create Question Content Email"
+ Then I should see "The question content email was created successfully" within ".flash.notice"
+
+ When I am on show "some question" question page
+ And I follow "content"
+ And I fill in "Some question." for "question_content_email[description]"
+ And press "Save"
+ Then I should see "Changes to the question content email were saved" within ".flash.notice"