allowed 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/allowed/limit.rb +1 -0
- data/spec/lib/allowed/limit_spec.rb +6 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b83e748a4e838b74f0fde18b565a70fc275c5a20
|
4
|
+
data.tar.gz: 0d303293277213a9d78846e9b377c64b0ba62dd0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 000cf8977c79b48d5146937437ed9882217430afb02b254a906b1d442352bf7db89aa1a45d1684831f80e0340665cfac0d295c2ba9c624746fc55275bb11ba03
|
7
|
+
data.tar.gz: 0d05ba8f62763fc240f2a11297e333698b8fde2315ce77b1e3c34980440d1815d82fb69fcd24a76667436ec84a03c8a666dd44c42c6e3dcd15d9573700b5e520
|
data/lib/allowed/limit.rb
CHANGED
@@ -61,6 +61,12 @@ describe Allowed::Limit, "#handle_throttles" do
|
|
61
61
|
|
62
62
|
expect(callback).to have_received(:call).with(subject).once
|
63
63
|
end
|
64
|
+
|
65
|
+
it "clears the failed throttles" do
|
66
|
+
subject.__send__(:handle_throttles)
|
67
|
+
|
68
|
+
expect(subject.instance_variable_get("@_throttle_failures")).to be_empty
|
69
|
+
end
|
64
70
|
end
|
65
71
|
|
66
72
|
describe Allowed::Limit, "#validate_throttles" do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: allowed
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tristan Dunn
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-06-
|
11
|
+
date: 2014-06-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|