summaryrefslogtreecommitdiff
path: root/help/test/unit
diff options
context:
space:
mode:
Diffstat (limited to 'help/test/unit')
-rw-r--r--help/test/unit/ticket_test.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/help/test/unit/ticket_test.rb b/help/test/unit/ticket_test.rb
index 04832d9..6c29d11 100644
--- a/help/test/unit/ticket_test.rb
+++ b/help/test/unit/ticket_test.rb
@@ -39,6 +39,12 @@ class TicketTest < ActiveSupport::TestCase
assert @sample.is_creator_validated?
end
+ test "destroy all tickets from a user" do
+ t = FactoryGirl.create :ticket_with_creator
+ u = t.created_by_user
+ Ticket.destroy_all_from(u)
+ assert_equal nil, Ticket.find(t.id)
+ end
=begin
# TODO: do once have current_user stuff in order
test "code if & only if not creator-validated" do