diff options
author | Petteri Räty <betelgeuse@gentoo.org> | 2011-03-12 21:13:18 +0200 |
---|---|---|
committer | Petteri Räty <betelgeuse@gentoo.org> | 2011-03-12 21:13:18 +0200 |
commit | c38161f8d317aee036f197a9b670f96dcd4c9ec3 (patch) | |
tree | 3ba7b4cd90a3bb5ea4a351c3c3221fd8de8603fd /features/step_definitions/questions_steps.rb | |
parent | Rename QuestionCategory to Category (diff) | |
download | recruiting-webapp-c38161f8d317aee036f197a9b670f96dcd4c9ec3.tar.gz recruiting-webapp-c38161f8d317aee036f197a9b670f96dcd4c9ec3.tar.bz2 recruiting-webapp-c38161f8d317aee036f197a9b670f96dcd4c9ec3.zip |
Questions can belong to many categories
While starting to input quiz questions for the arch tester quizzes we
found out that it would be best if questions could belong to many
categories. Now the relationship between questions and categories is
many to many. Bug #356179.
Diffstat (limited to 'features/step_definitions/questions_steps.rb')
-rw-r--r-- | features/step_definitions/questions_steps.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/features/step_definitions/questions_steps.rb b/features/step_definitions/questions_steps.rb index b0cd6fd..7f96e30 100644 --- a/features/step_definitions/questions_steps.rb +++ b/features/step_definitions/questions_steps.rb @@ -12,8 +12,7 @@ end Given /^a question "([^\"]*)" in category "([^\"]*)"$/ do |title, category| Given "a question \"#{title}\"" Given "a category \"#{category}\"" - @question.category = @category - @question.save! + QuestionCategory.create!(:category => @category, :question => @question) end Given /^a question "([^\"]*)" in group "([^\"]*)"$/ do |title, group| |