Add kmyblue original comments
This commit is contained in:
parent
721f6f9c97
commit
7d80e90976
1 changed files with 4 additions and 0 deletions
|
@ -7,6 +7,8 @@ RSpec.describe Rack::Attack, type: :request do
|
|||
Rails.application
|
||||
end
|
||||
|
||||
# kmyblue original fix for test error
|
||||
|
||||
def below_limit
|
||||
limit - 1
|
||||
end
|
||||
|
@ -27,6 +29,8 @@ RSpec.describe Rack::Attack, type: :request do
|
|||
described_class.cache.count("#{throttle}:#{discriminator}", period)
|
||||
end
|
||||
|
||||
# kmyblue original fix for test error (end)
|
||||
|
||||
shared_context 'with throttled endpoint base' do
|
||||
before do
|
||||
# Rack::Attack periods are not rolling, so avoid flaky tests by setting the time in a way
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue