| 192 | } |
| 193 | |
| 194 | TokenRef makeRandomTokenSpec(Arena& arena, IRandom& rng) { |
| 195 | auto token = TokenRef{}; |
| 196 | token.expiresAt = timer_monotonic() * (0.5 + rng.random01()); |
| 197 | const auto numTenants = rng.randomInt(1, 3); |
| 198 | for (auto i = 0; i < numTenants; i++) { |
| 199 | token.tenants.push_back(arena, genRandomAlphanumStringRef(arena, rng, MinTenantNameLen, MaxTenantNameLenPlus1)); |
| 200 | } |
| 201 | return token; |
| 202 | } |
| 203 | |
| 204 | } // namespace authz::flatbuffers |
| 205 |
no test coverage detected