fix(checks): wire error_buffer into test ServerConfigs + silence too-many-args #27

Merged
David merged 1 commit from fix/server-tests-and-clippy into main 2026-05-17 14:53:34 +02:00
Owner

Summary

Two strict-check failures on main after recent merges:

  1. E0063 in test ServerConfig literals. VS-7 (PR #19) added error_buffer: Option<ErrorBuffer> to ServerConfig but did not update the 6 ServerConfig literals in crates/meshcentral-web/tests/login.rs and tests/tls_smoke.rs. cargo check --workspace --all-targets (which just check-compile runs) failed.

  2. clippy too_many_arguments under -D warnings. event_log::list went from 7 -> 8 args when VS-8 added the tag filter; user_session::handle_satellite went from 7 -> 8 when VS-13 added session_guard. CI (.forgejo/workflows/check.yml) runs cargo clippy --all-targets -- -D warnings so these warnings are blocking. Workspace already uses #[allow(clippy::too_many_arguments)] on functions whose argument set is intrinsic to the dispatch shape; this PR does the same here.

Changes

  • tests/login.rs, tests/tls_smoke.rs: error_buffer: None, added after datapath: None, in every ServerConfig literal (6 sites).
  • event_log::list, user_session::handle_satellite: #[allow(clippy::too_many_arguments)] attribute added.
  • cargo fmt --all reformatting on a few touched files folded in.

Test plan

  • cargo check --workspace --all-targets clean.
  • cargo clippy --all-targets -- -D warnings clean.
  • cargo fmt --all --check clean.
  • just check exits 0.
## Summary Two strict-check failures on main after recent merges: 1. **E0063 in test ServerConfig literals.** VS-7 (PR #19) added `error_buffer: Option<ErrorBuffer>` to `ServerConfig` but did not update the 6 ServerConfig literals in `crates/meshcentral-web/tests/login.rs` and `tests/tls_smoke.rs`. `cargo check --workspace --all-targets` (which `just check-compile` runs) failed. 2. **clippy too_many_arguments under -D warnings.** `event_log::list` went from 7 -> 8 args when VS-8 added the `tag` filter; `user_session::handle_satellite` went from 7 -> 8 when VS-13 added `session_guard`. CI (`.forgejo/workflows/check.yml`) runs `cargo clippy --all-targets -- -D warnings` so these warnings are blocking. Workspace already uses `#[allow(clippy::too_many_arguments)]` on functions whose argument set is intrinsic to the dispatch shape; this PR does the same here. ## Changes - `tests/login.rs`, `tests/tls_smoke.rs`: `error_buffer: None,` added after `datapath: None,` in every ServerConfig literal (6 sites). - `event_log::list`, `user_session::handle_satellite`: `#[allow(clippy::too_many_arguments)]` attribute added. - `cargo fmt --all` reformatting on a few touched files folded in. ## Test plan - [x] `cargo check --workspace --all-targets` clean. - [x] `cargo clippy --all-targets -- -D warnings` clean. - [x] `cargo fmt --all --check` clean. - [x] `just check` exits 0.
fix(checks): wire error_buffer into test ServerConfigs + silence clippy too-many-args
All checks were successful
Create release / Create release from merged PR (pull_request) Has been skipped
Check / fmt + clippy + build + tests (pull_request) Successful in 5m20s
28bed49943
Recent merges into main left two strict-check failures:

1. `error_buffer` field added to `ServerConfig` by VS-7 (PR #19) was not initialized in any of the integration-test `ServerConfig { ... }` literals under `crates/meshcentral-web/tests/`. `cargo check --all-targets` failed with E0063 in 4 sites in `tests/login.rs` and 2 sites in `tests/tls_smoke.rs`. Adds `error_buffer: None,` after the existing `datapath: None,` line in each (the production binary still passes the buffer it builds in `init_tracing`; tests don't need one).

2. `event_log::list` (VS-8 added the `tag` filter, taking the arg count from 7 to 8) and `user_session::handle_satellite` (VS-13 added `session_guard`, taking it from 7 to 8) both tripped clippy's `too_many_arguments` lint, which CI runs under `-D warnings`. Adds `#[allow(clippy::too_many_arguments)]` to each. Other functions in this workspace already use the same allow when their parameter set is intrinsic to the dispatch shape (`run_server`, several other `user_session` handlers).

`cargo fmt --all` ran cleanly; cosmetic reformatting on a handful of touched files folded in.

Verified locally:
- `cargo check --workspace --all-targets` clean.
- `cargo clippy --all-targets -- -D warnings` clean.
- `cargo fmt --all --check` clean.
David merged commit 92305a9250 into main 2026-05-17 14:53:34 +02:00
David deleted branch fix/server-tests-and-clippy 2026-05-17 14:53:34 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
psa-systems/vervain-server!27
No description provided.