summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorshumakl <shumakl@purdue.edu>2014-04-03 11:19:10 -0400
committershumakl <shumakl@purdue.edu>2014-04-03 11:19:10 -0400
commitef22599880973aae8464bacb82e3a04d6277bc43 (patch)
tree92de5c3e91d83da6a8b473277c09dca2f6f21ed4 /test
parentf9a4ee4e998f5f113565a93802c041108e9a180d (diff)
Move things around between users and sessions
Diffstat (limited to 'test')
-rw-r--r--test/controllers/sessions_controller_test.rb4
-rw-r--r--test/fixtures/sessions.yml2
2 files changed, 4 insertions, 2 deletions
diff --git a/test/controllers/sessions_controller_test.rb b/test/controllers/sessions_controller_test.rb
index a5cc8cb..a144bf8 100644
--- a/test/controllers/sessions_controller_test.rb
+++ b/test/controllers/sessions_controller_test.rb
@@ -18,7 +18,7 @@ class SessionsControllerTest < ActionController::TestCase
test "should create session" do
assert_difference('Session.count') do
- post :create, session: { user_id: @session.user_id }
+ post :create, session: { token: @session.token, user_id: @session.user_id }
end
assert_redirected_to session_path(assigns(:session))
@@ -35,7 +35,7 @@ class SessionsControllerTest < ActionController::TestCase
end
test "should update session" do
- patch :update, id: @session, session: { user_id: @session.user_id }
+ patch :update, id: @session, session: { token: @session.token, user_id: @session.user_id }
assert_redirected_to session_path(assigns(:session))
end
diff --git a/test/fixtures/sessions.yml b/test/fixtures/sessions.yml
index d9098d9..aea4379 100644
--- a/test/fixtures/sessions.yml
+++ b/test/fixtures/sessions.yml
@@ -2,6 +2,8 @@
one:
user_id:
+ token: MyString
two:
user_id:
+ token: MyString