[tests] Testkit: test CA, echo and websocket upstreams, mock Authelia, clients

This commit is contained in:
2026-11-07 14:48:05 +01:00
parent a5823ba33d
commit a94a242c79
9 changed files with 3530 additions and 14 deletions
+24
View File
@@ -0,0 +1,24 @@
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at https://mozilla.org/MPL/2.0/.
//! Test fixtures shared by the edge integration tests and the differential harness.
//! Everything listens on 127.0.0.1 only. This is test code: panics are failures.
#![allow(clippy::unwrap_used, clippy::expect_used, clippy::panic)]
pub mod authelia;
pub mod client;
pub mod proc;
pub mod tls;
pub mod upstream;
/// FNV-1a 64-bit, used to compare bodies and secret values without echoing them.
pub fn fnv64(data: &[u8]) -> String {
let mut h: u64 = 0xcbf2_9ce4_8422_2325;
for b in data {
h ^= u64::from(*b);
h = h.wrapping_mul(0x0100_0000_01b3);
}
format!("{h:016x}")
}