summaryrefslogtreecommitdiff
path: root/users/test/functional
diff options
context:
space:
mode:
authorjessib <jessib@riseup.net>2013-12-31 11:48:18 -0800
committerjessib <jessib@riseup.net>2013-12-31 11:48:18 -0800
commitf9c96f8844205afe3c310b5b914752068728d38f (patch)
treee9e9d4e2d5e7d03946a3c7d4929c53b71ef1d952 /users/test/functional
parent4dae5eaa1bdb211d9d3ff29d5a9e9a86424e9748 (diff)
Cleanup of code for messages API and cron job for 1 month payment warning. Authentication still remaining piece.
Diffstat (limited to 'users/test/functional')
-rw-r--r--users/test/functional/v1/messages_controller_test.rb10
1 files changed, 0 insertions, 10 deletions
diff --git a/users/test/functional/v1/messages_controller_test.rb b/users/test/functional/v1/messages_controller_test.rb
index d7ada82..7666ba3 100644
--- a/users/test/functional/v1/messages_controller_test.rb
+++ b/users/test/functional/v1/messages_controller_test.rb
@@ -10,14 +10,9 @@ class V1::MessagesControllerTest < ActionController::TestCase
@user = FactoryGirl.build(:user)
@user.message_ids_to_see << @message.id
@user.save
-
- # @user_message = UserMessage.new(:message_id => @message.id, :user_id => @user.id)
- # @user_message.save
-
end
teardown do
- # @user_message.destroy
@user.destroy
@message.destroy
end
@@ -29,13 +24,10 @@ class V1::MessagesControllerTest < ActionController::TestCase
end
test "mark message read for user" do
- #assert !@user_message.seen
assert @user.message_ids_to_see.include?(@message.id)
assert !@user.message_ids_seen.include?(@message.id)
put :mark_read, :user_id => @user.id, :message_id => @message.id
- #@user_message.reload
- #assert @user_message.seen
@user.reload
assert !@user.message_ids_to_see.include?(@message.id)
assert @user.message_ids_seen.include?(@message.id)
@@ -43,8 +35,6 @@ class V1::MessagesControllerTest < ActionController::TestCase
end
test "do not get seen messages" do
- # @user_message.seen = true
- # @user_message.save
put :mark_read, :user_id => @user.id, :message_id => @message.id
@user.reload
get :user_messages, :user_id => @user.id