api-auth 1.5.0 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (53) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +10 -44
  3. data/.rubocop.yml +102 -0
  4. data/.travis.yml +1 -0
  5. data/Appraisals +8 -0
  6. data/CHANGELOG.md +8 -1
  7. data/Gemfile +3 -0
  8. data/README.md +33 -5
  9. data/VERSION +1 -1
  10. data/api_auth.gemspec +17 -17
  11. data/gemfiles/rails_23.gemfile +3 -0
  12. data/gemfiles/rails_30.gemfile +3 -0
  13. data/gemfiles/rails_31.gemfile +5 -0
  14. data/gemfiles/rails_32.gemfile +5 -0
  15. data/gemfiles/rails_4.gemfile +2 -0
  16. data/gemfiles/rails_41.gemfile +2 -0
  17. data/gemfiles/rails_42.gemfile +2 -0
  18. data/lib/api-auth.rb +1 -1
  19. data/lib/api_auth/base.rb +21 -25
  20. data/lib/api_auth/errors.rb +4 -3
  21. data/lib/api_auth/headers.rb +11 -27
  22. data/lib/api_auth/helpers.rb +2 -6
  23. data/lib/api_auth/railtie.rb +5 -50
  24. data/lib/api_auth/request_drivers/action_controller.rb +7 -13
  25. data/lib/api_auth/request_drivers/action_dispatch.rb +0 -6
  26. data/lib/api_auth/request_drivers/curb.rb +8 -14
  27. data/lib/api_auth/request_drivers/faraday.rb +11 -21
  28. data/lib/api_auth/request_drivers/httpi.rb +8 -14
  29. data/lib/api_auth/request_drivers/net_http.rb +8 -14
  30. data/lib/api_auth/request_drivers/rack.rb +10 -16
  31. data/lib/api_auth/request_drivers/rest_client.rb +9 -15
  32. data/spec/api_auth_spec.rb +90 -88
  33. data/spec/headers_spec.rb +69 -84
  34. data/spec/helpers_spec.rb +7 -9
  35. data/spec/railtie_spec.rb +42 -72
  36. data/spec/request_drivers/action_controller_spec.rb +53 -55
  37. data/spec/request_drivers/action_dispatch_spec.rb +52 -55
  38. data/spec/request_drivers/curb_spec.rb +25 -28
  39. data/spec/request_drivers/faraday_spec.rb +54 -56
  40. data/spec/request_drivers/httpi_spec.rb +42 -48
  41. data/spec/request_drivers/net_http_spec.rb +51 -53
  42. data/spec/request_drivers/rack_spec.rb +58 -60
  43. data/spec/request_drivers/rest_client_spec.rb +86 -89
  44. data/spec/spec_helper.rb +9 -9
  45. metadata +4 -11
  46. data/Gemfile.lock +0 -115
  47. data/gemfiles/rails_23.gemfile.lock +0 -70
  48. data/gemfiles/rails_30.gemfile.lock +0 -92
  49. data/gemfiles/rails_31.gemfile.lock +0 -98
  50. data/gemfiles/rails_32.gemfile.lock +0 -97
  51. data/gemfiles/rails_4.gemfile.lock +0 -94
  52. data/gemfiles/rails_41.gemfile.lock +0 -98
  53. data/gemfiles/rails_42.gemfile.lock +0 -115
@@ -1,19 +1,18 @@
1
1
  require 'spec_helper'
2
2
 
3
3
  describe ApiAuth::RequestDrivers::NetHttpRequest do
4
+ let(:timestamp) { Time.now.utc.httpdate }
4
5
 
5
- let(:timestamp){ Time.now.utc.httpdate }
6
+ let(:request_path) { '/resource.xml?foo=bar&bar=foo' }
6
7
 
7
- let(:request_path){ "/resource.xml?foo=bar&bar=foo" }
8
-
9
- let(:request_headers){
8
+ let(:request_headers) do
10
9
  {
11
- 'Authorization' => 'APIAuth 1044:12345',
10
+ 'Authorization' => 'APIAuth 1044:12345',
12
11
  'content-md5' => '1B2M2Y8AsgTpgAmY7PhCfg==',
13
12
  'content-type' => 'text/plain',
14
13
  'date' => timestamp
15
14
  }
16
- }
15
+ end
17
16
 
18
17
  let(:request) do
19
18
  net_http_request = Net::HTTP::Put.new(request_path, request_headers)
@@ -21,175 +20,174 @@ describe ApiAuth::RequestDrivers::NetHttpRequest do
21
20
  net_http_request
22
21
  end
23
22
 
24
- subject(:driven_request){ ApiAuth::RequestDrivers::NetHttpRequest.new(request) }
23
+ subject(:driven_request) { ApiAuth::RequestDrivers::NetHttpRequest.new(request) }
25
24
 
26
- describe "getting headers correctly" do
27
- describe "#content_type" do
28
- it "gets the content_type" do
25
+ describe 'getting headers correctly' do
26
+ describe '#content_type' do
27
+ it 'gets the content_type' do
29
28
  expect(driven_request.content_type).to eq('text/plain')
30
29
  end
31
30
 
32
- it "gets multipart content_type" do
33
- request = Net::HTTP::Put::Multipart.new("/resource.xml?foo=bar&bar=foo",
34
- 'file' => UploadIO.new(File.new('spec/fixtures/upload.png'), 'image/png', 'upload.png'))
31
+ it 'gets multipart content_type' do
32
+ request = Net::HTTP::Put::Multipart.new('/resource.xml?foo=bar&bar=foo',
33
+ 'file' => UploadIO.new(File.new('spec/fixtures/upload.png'), 'image/png', 'upload.png'))
35
34
  driven_request = ApiAuth::RequestDrivers::NetHttpRequest.new(request)
36
35
  expect(driven_request.content_type).to match 'multipart/form-data; boundary='
37
36
  end
38
37
  end
39
38
 
40
- it "gets the content_md5" do
39
+ it 'gets the content_md5' do
41
40
  expect(driven_request.content_md5).to eq('1B2M2Y8AsgTpgAmY7PhCfg==')
42
41
  end
43
42
 
44
- it "gets the request_uri" do
43
+ it 'gets the request_uri' do
45
44
  expect(driven_request.request_uri).to eq('/resource.xml?foo=bar&bar=foo')
46
45
  end
47
46
 
48
- it "gets the timestamp" do
47
+ it 'gets the timestamp' do
49
48
  expect(driven_request.timestamp).to eq(timestamp)
50
49
  end
51
50
 
52
- it "gets the authorization_header" do
51
+ it 'gets the authorization_header' do
53
52
  expect(driven_request.authorization_header).to eq('APIAuth 1044:12345')
54
53
  end
55
54
 
56
- describe "#calculated_md5" do
57
- it "calculates md5 from the body" do
55
+ describe '#calculated_md5' do
56
+ it 'calculates md5 from the body' do
58
57
  expect(driven_request.calculated_md5).to eq('kZXQvrKoieG+Be1rsZVINw==')
59
58
  end
60
59
 
61
- it "treats no body as empty string" do
60
+ it 'treats no body as empty string' do
62
61
  request.body = nil
63
62
  expect(driven_request.calculated_md5).to eq('1B2M2Y8AsgTpgAmY7PhCfg==')
64
63
  end
65
64
 
66
- it "calculates correctly for multipart content" do
65
+ it 'calculates correctly for multipart content' do
67
66
  request.body = nil
68
67
  request.body_stream = File.new('spec/fixtures/upload.png')
69
68
  expect(driven_request.calculated_md5).to eq('k4U8MTA3RHDcewBzymVNEQ==')
70
69
  end
71
70
  end
72
71
 
73
- describe "http_method" do
74
- context "when put request" do
75
- let(:request){ Net::HTTP::Put.new(request_path, request_headers) }
72
+ describe 'http_method' do
73
+ context 'when put request' do
74
+ let(:request) { Net::HTTP::Put.new(request_path, request_headers) }
76
75
 
77
- it "returns upcased put" do
76
+ it 'returns upcased put' do
78
77
  expect(driven_request.http_method).to eq('PUT')
79
78
  end
80
79
  end
81
80
 
82
- context "when get request" do
83
- let(:request){ Net::HTTP::Get.new(request_path, request_headers) }
81
+ context 'when get request' do
82
+ let(:request) { Net::HTTP::Get.new(request_path, request_headers) }
84
83
 
85
- it "returns upcased get" do
84
+ it 'returns upcased get' do
86
85
  expect(driven_request.http_method).to eq('GET')
87
86
  end
88
87
  end
89
88
  end
90
89
  end
91
90
 
92
- describe "setting headers correctly" do
93
- let(:request_headers){
91
+ describe 'setting headers correctly' do
92
+ let(:request_headers) do
94
93
  {
95
94
  'content-type' => 'text/plain'
96
95
  }
97
- }
96
+ end
98
97
 
99
98
  let(:request) do
100
99
  Net::HTTP::Put.new(request_path, request_headers)
101
100
  end
102
101
 
103
- describe "#populate_content_md5" do
104
- context "when request type has no body" do
102
+ describe '#populate_content_md5' do
103
+ context 'when request type has no body' do
105
104
  let(:request) do
106
105
  Net::HTTP::Get.new(request_path, request_headers)
107
106
  end
108
107
 
109
108
  it "doesn't populate content-md5" do
110
109
  driven_request.populate_content_md5
111
- expect(request["Content-MD5"]).to be_nil
110
+ expect(request['Content-MD5']).to be_nil
112
111
  end
113
112
  end
114
113
 
115
- context "when request type has a body" do
114
+ context 'when request type has a body' do
116
115
  let(:request) do
117
116
  net_http_request = Net::HTTP::Put.new(request_path, request_headers)
118
117
  net_http_request.body = "hello\nworld"
119
118
  net_http_request
120
119
  end
121
120
 
122
- it "populates content-md5" do
121
+ it 'populates content-md5' do
123
122
  driven_request.populate_content_md5
124
- expect(request["Content-MD5"]).to eq('kZXQvrKoieG+Be1rsZVINw==')
123
+ expect(request['Content-MD5']).to eq('kZXQvrKoieG+Be1rsZVINw==')
125
124
  end
126
125
 
127
- it "refreshes the cached headers" do
126
+ it 'refreshes the cached headers' do
128
127
  driven_request.populate_content_md5
129
128
  expect(driven_request.content_md5).to eq('kZXQvrKoieG+Be1rsZVINw==')
130
129
  end
131
130
  end
132
131
  end
133
132
 
134
- describe "#set_date" do
133
+ describe '#set_date' do
135
134
  before do
136
135
  allow(Time).to receive_message_chain(:now, :utc, :httpdate).and_return(timestamp)
137
136
  end
138
137
 
139
- it "sets the date header of the request" do
138
+ it 'sets the date header of the request' do
140
139
  driven_request.set_date
141
140
  expect(request['DATE']).to eq(timestamp)
142
141
  end
143
142
 
144
- it "refreshes the cached headers" do
143
+ it 'refreshes the cached headers' do
145
144
  driven_request.set_date
146
145
  expect(driven_request.timestamp).to eq(timestamp)
147
146
  end
148
147
  end
149
148
 
150
- describe "#set_auth_header" do
151
- it "sets the auth header" do
149
+ describe '#set_auth_header' do
150
+ it 'sets the auth header' do
152
151
  driven_request.set_auth_header('APIAuth 1044:54321')
153
152
  expect(request['Authorization']).to eq('APIAuth 1044:54321')
154
153
  end
155
154
  end
156
155
  end
157
156
 
158
- describe "md5_mismatch?" do
159
- context "when request type has no body" do
157
+ describe 'md5_mismatch?' do
158
+ context 'when request type has no body' do
160
159
  let(:request) do
161
160
  Net::HTTP::Get.new(request_path, request_headers)
162
161
  end
163
162
 
164
-
165
- it "is false" do
163
+ it 'is false' do
166
164
  expect(driven_request.md5_mismatch?).to be false
167
165
  end
168
166
  end
169
167
 
170
- context "when request type has a body" do
168
+ context 'when request type has a body' do
171
169
  let(:request) do
172
170
  net_http_request = Net::HTTP::Put.new(request_path, request_headers)
173
171
  net_http_request.body = "hello\nworld"
174
172
  net_http_request
175
173
  end
176
174
 
177
- context "when calculated matches sent" do
175
+ context 'when calculated matches sent' do
178
176
  before do
179
- request["Content-MD5"] = 'kZXQvrKoieG+Be1rsZVINw=='
177
+ request['Content-MD5'] = 'kZXQvrKoieG+Be1rsZVINw=='
180
178
  end
181
179
 
182
- it "is false" do
180
+ it 'is false' do
183
181
  expect(driven_request.md5_mismatch?).to be false
184
182
  end
185
183
  end
186
184
 
187
185
  context "when calculated doesn't match sent" do
188
186
  before do
189
- request["Content-MD5"] = "3"
187
+ request['Content-MD5'] = '3'
190
188
  end
191
189
 
192
- it "is true" do
190
+ it 'is true' do
193
191
  expect(driven_request.md5_mismatch?).to be true
194
192
  end
195
193
  end
@@ -1,19 +1,18 @@
1
1
  require 'spec_helper'
2
2
 
3
3
  describe ApiAuth::RequestDrivers::RackRequest do
4
+ let(:timestamp) { Time.now.utc.httpdate }
4
5
 
5
- let(:timestamp){ Time.now.utc.httpdate }
6
+ let(:request_path) { '/resource.xml?foo=bar&bar=foo' }
6
7
 
7
- let(:request_path){ "/resource.xml?foo=bar&bar=foo" }
8
-
9
- let(:request_headers){
8
+ let(:request_headers) do
10
9
  {
11
- 'Authorization' => 'APIAuth 1044:12345',
10
+ 'Authorization' => 'APIAuth 1044:12345',
12
11
  'Content-MD5' => '1B2M2Y8AsgTpgAmY7PhCfg==',
13
12
  'Content-Type' => 'text/plain',
14
13
  'Date' => timestamp
15
14
  }
16
- }
15
+ end
17
16
 
18
17
  let(:request) do
19
18
  Rack::Request.new(
@@ -25,35 +24,35 @@ describe ApiAuth::RequestDrivers::RackRequest do
25
24
  )
26
25
  end
27
26
 
28
- subject(:driven_request){ ApiAuth::RequestDrivers::RackRequest.new(request) }
27
+ subject(:driven_request) { ApiAuth::RequestDrivers::RackRequest.new(request) }
29
28
 
30
- describe "getting headers correctly" do
31
- it "gets the content_type" do
29
+ describe 'getting headers correctly' do
30
+ it 'gets the content_type' do
32
31
  expect(driven_request.content_type).to eq('text/plain')
33
32
  end
34
33
 
35
- it "gets the content_md5" do
34
+ it 'gets the content_md5' do
36
35
  expect(driven_request.content_md5).to eq('1B2M2Y8AsgTpgAmY7PhCfg==')
37
36
  end
38
37
 
39
- it "gets the request_uri" do
38
+ it 'gets the request_uri' do
40
39
  expect(driven_request.request_uri).to eq('/resource.xml?foo=bar&bar=foo')
41
40
  end
42
41
 
43
- it "gets the timestamp" do
42
+ it 'gets the timestamp' do
44
43
  expect(driven_request.timestamp).to eq(timestamp)
45
44
  end
46
45
 
47
- it "gets the authorization_header" do
46
+ it 'gets the authorization_header' do
48
47
  expect(driven_request.authorization_header).to eq('APIAuth 1044:12345')
49
48
  end
50
49
 
51
- describe "#calculated_md5" do
52
- it "calculates md5 from the body" do
50
+ describe '#calculated_md5' do
51
+ it 'calculates md5 from the body' do
53
52
  expect(driven_request.calculated_md5).to eq('kZXQvrKoieG+Be1rsZVINw==')
54
53
  end
55
54
 
56
- it "treats no body as empty string" do
55
+ it 'treats no body as empty string' do
57
56
  request = Rack::Request.new(
58
57
  Rack::MockRequest.env_for(
59
58
  request_path,
@@ -65,8 +64,8 @@ describe ApiAuth::RequestDrivers::RackRequest do
65
64
  end
66
65
  end
67
66
 
68
- describe "http_method" do
69
- context "when put request" do
67
+ describe 'http_method' do
68
+ context 'when put request' do
70
69
  let(:request) do
71
70
  Rack::Request.new(
72
71
  Rack::MockRequest.env_for(
@@ -76,12 +75,12 @@ describe ApiAuth::RequestDrivers::RackRequest do
76
75
  )
77
76
  end
78
77
 
79
- it "returns upcased put" do
78
+ it 'returns upcased put' do
80
79
  expect(driven_request.http_method).to eq('PUT')
81
80
  end
82
81
  end
83
82
 
84
- context "when get request" do
83
+ context 'when get request' do
85
84
  let(:request) do
86
85
  Rack::Request.new(
87
86
  Rack::MockRequest.env_for(
@@ -91,22 +90,22 @@ describe ApiAuth::RequestDrivers::RackRequest do
91
90
  )
92
91
  end
93
92
 
94
- it "returns upcased get" do
93
+ it 'returns upcased get' do
95
94
  expect(driven_request.http_method).to eq('GET')
96
95
  end
97
96
  end
98
97
  end
99
98
  end
100
99
 
101
- describe "setting headers correctly" do
102
- let(:request_headers){
100
+ describe 'setting headers correctly' do
101
+ let(:request_headers) do
103
102
  {
104
103
  'content-type' => 'text/plain'
105
104
  }
106
- }
105
+ end
107
106
 
108
- describe "#populate_content_md5" do
109
- context "when getting" do
107
+ describe '#populate_content_md5' do
108
+ context 'when getting' do
110
109
  let(:request) do
111
110
  Rack::Request.new(
112
111
  Rack::MockRequest.env_for(
@@ -118,11 +117,11 @@ describe ApiAuth::RequestDrivers::RackRequest do
118
117
 
119
118
  it "doesn't populate content-md5" do
120
119
  driven_request.populate_content_md5
121
- expect(request.env["Content-MD5"]).to be_nil
120
+ expect(request.env['Content-MD5']).to be_nil
122
121
  end
123
122
  end
124
123
 
125
- context "when posting" do
124
+ context 'when posting' do
126
125
  let(:request) do
127
126
  Rack::Request.new(
128
127
  Rack::MockRequest.env_for(
@@ -133,18 +132,18 @@ describe ApiAuth::RequestDrivers::RackRequest do
133
132
  )
134
133
  end
135
134
 
136
- it "populates content-md5" do
135
+ it 'populates content-md5' do
137
136
  driven_request.populate_content_md5
138
- expect(request.env["Content-MD5"]).to eq('kZXQvrKoieG+Be1rsZVINw==')
137
+ expect(request.env['Content-MD5']).to eq('kZXQvrKoieG+Be1rsZVINw==')
139
138
  end
140
139
 
141
- it "refreshes the cached headers" do
140
+ it 'refreshes the cached headers' do
142
141
  driven_request.populate_content_md5
143
142
  expect(driven_request.content_md5).to eq('kZXQvrKoieG+Be1rsZVINw==')
144
143
  end
145
144
  end
146
145
 
147
- context "when putting" do
146
+ context 'when putting' do
148
147
  let(:request) do
149
148
  Rack::Request.new(
150
149
  Rack::MockRequest.env_for(
@@ -155,18 +154,18 @@ describe ApiAuth::RequestDrivers::RackRequest do
155
154
  )
156
155
  end
157
156
 
158
- it "populates content-md5" do
157
+ it 'populates content-md5' do
159
158
  driven_request.populate_content_md5
160
- expect(request.env["Content-MD5"]).to eq('kZXQvrKoieG+Be1rsZVINw==')
159
+ expect(request.env['Content-MD5']).to eq('kZXQvrKoieG+Be1rsZVINw==')
161
160
  end
162
161
 
163
- it "refreshes the cached headers" do
162
+ it 'refreshes the cached headers' do
164
163
  driven_request.populate_content_md5
165
164
  expect(driven_request.content_md5).to eq('kZXQvrKoieG+Be1rsZVINw==')
166
165
  end
167
166
  end
168
167
 
169
- context "when deleting" do
168
+ context 'when deleting' do
170
169
  let(:request) do
171
170
  Rack::Request.new(
172
171
  Rack::MockRequest.env_for(
@@ -178,38 +177,37 @@ describe ApiAuth::RequestDrivers::RackRequest do
178
177
 
179
178
  it "doesn't populate content-md5" do
180
179
  driven_request.populate_content_md5
181
- expect(request.env["Content-MD5"]).to be_nil
180
+ expect(request.env['Content-MD5']).to be_nil
182
181
  end
183
182
  end
184
-
185
183
  end
186
184
 
187
- describe "#set_date" do
185
+ describe '#set_date' do
188
186
  before do
189
187
  allow(Time).to receive_message_chain(:now, :utc, :httpdate).and_return(timestamp)
190
188
  end
191
189
 
192
- it "sets the date header of the request" do
190
+ it 'sets the date header of the request' do
193
191
  driven_request.set_date
194
192
  expect(request.env['DATE']).to eq(timestamp)
195
193
  end
196
194
 
197
- it "refreshes the cached headers" do
195
+ it 'refreshes the cached headers' do
198
196
  driven_request.set_date
199
197
  expect(driven_request.timestamp).to eq(timestamp)
200
198
  end
201
199
  end
202
200
 
203
- describe "#set_auth_header" do
204
- it "sets the auth header" do
201
+ describe '#set_auth_header' do
202
+ it 'sets the auth header' do
205
203
  driven_request.set_auth_header('APIAuth 1044:54321')
206
204
  expect(request.env['Authorization']).to eq('APIAuth 1044:54321')
207
205
  end
208
206
  end
209
207
  end
210
208
 
211
- describe "md5_mismatch?" do
212
- context "when getting" do
209
+ describe 'md5_mismatch?' do
210
+ context 'when getting' do
213
211
  let(:request) do
214
212
  Rack::Request.new(
215
213
  Rack::MockRequest.env_for(
@@ -219,12 +217,12 @@ describe ApiAuth::RequestDrivers::RackRequest do
219
217
  )
220
218
  end
221
219
 
222
- it "is false" do
220
+ it 'is false' do
223
221
  expect(driven_request.md5_mismatch?).to be false
224
222
  end
225
223
  end
226
224
 
227
- context "when posting" do
225
+ context 'when posting' do
228
226
  let(:request) do
229
227
  Rack::Request.new(
230
228
  Rack::MockRequest.env_for(
@@ -235,28 +233,28 @@ describe ApiAuth::RequestDrivers::RackRequest do
235
233
  )
236
234
  end
237
235
 
238
- context "when calculated matches sent" do
236
+ context 'when calculated matches sent' do
239
237
  before do
240
- request.env["Content-MD5"] = 'kZXQvrKoieG+Be1rsZVINw=='
238
+ request.env['Content-MD5'] = 'kZXQvrKoieG+Be1rsZVINw=='
241
239
  end
242
240
 
243
- it "is false" do
241
+ it 'is false' do
244
242
  expect(driven_request.md5_mismatch?).to be false
245
243
  end
246
244
  end
247
245
 
248
246
  context "when calculated doesn't match sent" do
249
247
  before do
250
- request.env["Content-MD5"] = "3"
248
+ request.env['Content-MD5'] = '3'
251
249
  end
252
250
 
253
- it "is true" do
251
+ it 'is true' do
254
252
  expect(driven_request.md5_mismatch?).to be true
255
253
  end
256
254
  end
257
255
  end
258
256
 
259
- context "when putting" do
257
+ context 'when putting' do
260
258
  let(:request) do
261
259
  Rack::Request.new(
262
260
  Rack::MockRequest.env_for(
@@ -267,28 +265,28 @@ describe ApiAuth::RequestDrivers::RackRequest do
267
265
  )
268
266
  end
269
267
 
270
- context "when calculated matches sent" do
268
+ context 'when calculated matches sent' do
271
269
  before do
272
- request.env["Content-MD5"] = 'kZXQvrKoieG+Be1rsZVINw=='
270
+ request.env['Content-MD5'] = 'kZXQvrKoieG+Be1rsZVINw=='
273
271
  end
274
272
 
275
- it "is false" do
273
+ it 'is false' do
276
274
  expect(driven_request.md5_mismatch?).to be false
277
275
  end
278
276
  end
279
277
 
280
278
  context "when calculated doesn't match sent" do
281
279
  before do
282
- request.env["Content-MD5"] = "3"
280
+ request.env['Content-MD5'] = '3'
283
281
  end
284
282
 
285
- it "is true" do
283
+ it 'is true' do
286
284
  expect(driven_request.md5_mismatch?).to be true
287
285
  end
288
286
  end
289
287
  end
290
288
 
291
- context "when deleting" do
289
+ context 'when deleting' do
292
290
  let(:request) do
293
291
  Rack::Request.new(
294
292
  Rack::MockRequest.env_for(
@@ -298,7 +296,7 @@ describe ApiAuth::RequestDrivers::RackRequest do
298
296
  )
299
297
  end
300
298
 
301
- it "is false" do
299
+ it 'is false' do
302
300
  expect(driven_request.md5_mismatch?).to be false
303
301
  end
304
302
  end