X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/8a6e8ae128d3cc9a991d119c45b9ddb13e848f97..d102c9aaf478a4bad52a72b1b72470ba35ba464e:/test/models/oauth_token_test.rb?ds=sidebyside diff --git a/test/models/oauth_token_test.rb b/test/models/oauth_token_test.rb index c2df0d131..4b0e39e9a 100644 --- a/test/models/oauth_token_test.rb +++ b/test/models/oauth_token_test.rb @@ -1,8 +1,6 @@ require "test_helper" class OauthTokenTest < ActiveSupport::TestCase - api_fixtures - ## # check that after calling invalidate! on a token, it is invalid. def test_token_invalidation @@ -17,7 +15,7 @@ class OauthTokenTest < ActiveSupport::TestCase def test_token_authorisation tok = RequestToken.create(:client_application => create(:client_application)) assert_equal false, tok.authorized?, "Token should be created unauthorised." - tok.authorize!(users(:public_user)) + tok.authorize!(create(:user)) assert_equal true, tok.authorized?, "Token should now be authorised." tok.invalidate! assert_equal false, tok.authorized?, "Token should now be invalid."