+
+ test "note permissions for a guest" do
+ ability = Ability.new nil
+
+ [:mine].each do |action|
+ assert ability.can?(action, Note), "should be able to #{action} Notes"
+ end
+ end
+
+ test "user roles permissions for a guest" do
+ ability = Ability.new nil
+
+ [:grant, :revoke].each do |action|
+ assert ability.cannot?(action, UserRole), "should not be able to #{action} UserRoles"
+ end
+ end