This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| frozen_string_literal: true | |
| # A leaky bucket rate limiter for Ruby | |
| # | |
| # @see https://www.mikeperham.com/2020/11/09/the-leaky-bucket-rate-limiter/ | |
| # @see https://en.wikipedia.org/wiki/Leaky_bucket | |
| class RateLimit | |
| class Error < StandardError | |
| attr_accessor :retry_in |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class RoutingTest < ActionDispatch::IntegrationTest | |
| IGNORED_CONTROLLERS = Set[ | |
| "Rails::MailersController" | |
| ] | |
| test "no unrouted actions (public controller methods)" do | |
| actions_by_controller.each do |controller_path, actions| | |
| controller_name = "#{controller_path.camelize}Controller" | |
| next if IGNORED_CONTROLLERS.include?(controller_name) |
OlderNewer