aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoachim Filip Ignacy Bartosik <jbartosik@gmail.com>2010-06-23 11:32:26 +0200
committerJoachim Filip Ignacy Bartosik <jbartosik@gmail.com>2010-06-24 22:32:32 +0200
commit8922487a577a3258819d9329550efde326b136bc (patch)
tree0e373f0159e44ab30b05d62630966e9510b8e254 /spec/support
parentMentor demoting to recruit (diff)
downloadrecruiting-webapp-8922487a577a3258819d9329550efde326b136bc.tar.gz
recruiting-webapp-8922487a577a3258819d9329550efde326b136bc.tar.bz2
recruiting-webapp-8922487a577a3258819d9329550efde326b136bc.zip
Support for mentor comments
Generated Comment model and CommentsController. Added relation (answer has many comments, comment belongs to answer). Added email notification when new comment is created. This commit includes also schema change and tests.
Diffstat (limited to 'spec/support')
-rw-r--r--spec/support/test_permissions.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/spec/support/test_permissions.rb b/spec/support/test_permissions.rb
index a6624c0..5593c85 100644
--- a/spec/support/test_permissions.rb
+++ b/spec/support/test_permissions.rb
@@ -16,6 +16,13 @@ module Permissions
end
end
+ def ud_allowed( users, testee)
+ for user in users
+ testee.should be_updatable_by(user)
+ testee.should be_destroyable_by(user)
+ end
+ end
+
def ud_denied( users, testee)
for user in users
testee.should_not be_updatable_by(user)