summaryrefslogtreecommitdiff
path: root/test/support
diff options
context:
space:
mode:
Diffstat (limited to 'test/support')
-rw-r--r--test/support/api_integration_test.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/support/api_integration_test.rb b/test/support/api_integration_test.rb
index 0e8e261..bd10f11 100644
--- a/test/support/api_integration_test.rb
+++ b/test/support/api_integration_test.rb
@@ -5,7 +5,8 @@ class ApiIntegrationTest < ActionDispatch::IntegrationTest
def login(user = nil)
@user ||= user ||= FactoryGirl.create(:user)
- @token ||= DUMMY_TOKEN
+ # DUMMY_TOKEN will be frozen. So let's use a dup
+ @token ||= DUMMY_TOKEN.dup
# make sure @token is up to date if it already exists
@token.reload if @token.persisted?
@token.user_id = @user.id