docbrown/spec/helpers/rate_limit_checker_helper_spec.rb
Michael Kohl d2a929017d
Add RateLimitCheckerHelper (#7705)
* Implement review comments

* Add RateLimitCheckerHelper
2020-05-07 16:25:48 +02:00

12 lines
385 B
Ruby

require "rails_helper"
describe RateLimitCheckerHelper, type: :helper do
describe "#configurable_rate_limits" do
it "returns a hash with the right structure" do
helper.configurable_rate_limits.each do |key, value_hash|
expect(key).to match(/\Arate_limit/)
expect(value_hash.keys).to match_array(%i[min placeholder description])
end
end
end
end