diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2016-08-16 04:30:11 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2016-08-16 04:30:11 -0300 |
commit | 55f9b8129a50206513264824abb44088230793c2 (patch) | |
tree | ff2f01cabfc7e74b0bd831c2272a5517e4e81e99 /actionpack/test/controller/http_token_authentication_test.rb | |
parent | d0bdd74d7f6fae3d69b3681d5bc2d5ef6f55a0f8 (diff) | |
download | rails-55f9b8129a50206513264824abb44088230793c2.tar.gz rails-55f9b8129a50206513264824abb44088230793c2.tar.bz2 rails-55f9b8129a50206513264824abb44088230793c2.zip |
Add three new rubocop rules
Style/SpaceBeforeBlockBraces
Style/SpaceInsideBlockBraces
Style/SpaceInsideHashLiteralBraces
Fix all violations in the repository.
Diffstat (limited to 'actionpack/test/controller/http_token_authentication_test.rb')
-rw-r--r-- | actionpack/test/controller/http_token_authentication_test.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/test/controller/http_token_authentication_test.rb b/actionpack/test/controller/http_token_authentication_test.rb index b7a4c550d7..3842136682 100644 --- a/actionpack/test/controller/http_token_authentication_test.rb +++ b/actionpack/test/controller/http_token_authentication_test.rb @@ -156,10 +156,10 @@ class HttpTokenAuthenticationTest < ActionController::TestCase test "token_and_options returns correct token with nounce option" do token = "rcHu+HzSFw89Ypyhn/896A=" - nonce_hash = {nonce: "123abc"} + nonce_hash = { nonce: "123abc" } actual = ActionController::HttpAuthentication::Token.token_and_options(sample_request(token, nonce_hash)) expected_token = token - expected_nonce = {"nonce" => nonce_hash[:nonce]} + expected_nonce = { "nonce" => nonce_hash[:nonce] } assert_equal(expected_token, actual.first) assert_equal(expected_nonce, actual.last) end @@ -190,7 +190,7 @@ class HttpTokenAuthenticationTest < ActionController::TestCase private - def sample_request(token, options = {nonce: "def"}) + def sample_request(token, options = { nonce: "def" }) authorization = options.inject([%{Token token="#{token}"}]) do |arr, (k, v)| arr << "#{k}=\"#{v}\"" end.join(", ") |