]> git.ipfire.org Git - thirdparty/rspamd.git/commit
[Test] upstream: add token bucket unit tests 5874/head
authorVsevolod Stakhov <vsevolod@rspamd.com>
Fri, 6 Feb 2026 09:26:39 +0000 (09:26 +0000)
committerVsevolod Stakhov <vsevolod@rspamd.com>
Fri, 6 Feb 2026 09:26:39 +0000 (09:26 +0000)
commit1bdb8a6047f42351bceec2044bcf751b21472ca4
tree09e2d5d98594ceeba62207d5b9cd029924927ae0
parent61bed05c2c384ef8b3976bf8d43e9ecc725a1f9b
[Test] upstream: add token bucket unit tests

15 doctest test cases covering token bucket load balancing:
basic selection, cost formula, token return/penalty, least-loaded
preference, except parameter, exhaustion fallback, fair distribution,
custom config, empty list, null safety, large messages, multiple
inflight, mixed success/failure, and generic API fallback.
test/rspamd_cxx_unit.cxx
test/rspamd_cxx_unit_upstream_token_bucket.hxx [new file with mode: 0644]