benchmark-http 0.10.0 → 0.11.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '069082c04439ca3f6d2a49daa213721646b46051c0ea6b9c55d0247adfdcbeaf'
4
- data.tar.gz: 041fc41a0379bac2264ff90dde3dbc03ef6a20216deeb75fa3fdb818294bdf7f
3
+ metadata.gz: 7a53d525fad87d3fd01937e054c06f70afd6863e1ead842c02f1457aed6046e8
4
+ data.tar.gz: 5f008ffaa18ce21f8b91beaea253c334f929ef5d0e7dfbecb87ee5f17cb2f0a0
5
5
  SHA512:
6
- metadata.gz: 8ff5661cfa6ee80bbd0737b87a872da7e180bdb27536dbcc321625e331c8557333e314a1eedc9f1af1e9924cb556146540463aed89242b186c336032bd892289
7
- data.tar.gz: b842c305fc9ab7a18bb1c0f7dbcc2e6b7933dbae5cdfed237b040fa2c1a79edc16cfdc74083213067feca4493cda4a16d4f670e654d668e3870335f2090776ce
6
+ metadata.gz: 2258aa956ac4bf36560954aa0f517f938f5fb8c5348cd0c60994b846cb6489c6a859a76fe1de8fe62faab5a912691f20b9e8f72b221c1c7b23b098fd79ae1fc1
7
+ data.tar.gz: 9399cb6ffe0220222ee2b67f3949ff5e287286ad2e9ea1e06adf1438ed13ae9a5856913bf7787b0b97e8700e58cdee182c28fe983bcadc1224345226440ef4e2
@@ -160,6 +160,12 @@ module Benchmark
160
160
  @responses = Hash.new{|h,k| 0}
161
161
  end
162
162
 
163
+ attr :responses
164
+
165
+ def failed
166
+ @responses.sum{|status, count| status >= 400 ? count : 0}
167
+ end
168
+
163
169
  def add(duration, result)
164
170
  super
165
171
 
@@ -20,6 +20,6 @@
20
20
 
21
21
  module Benchmark
22
22
  module HTTP
23
- VERSION = "0.10.0"
23
+ VERSION = "0.11.0"
24
24
  end
25
25
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: benchmark-http
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams