Skip to content

Commit d2f51b9

Browse files
test: comprehensive handler tests for all NIP-46 methods
21 tests covering all 13 request variants plus bonus cases: frozen protocol vectors, permission gating, rate limiting, proof round-trips, sign_event wire format, switch-by-npub, and recover cache population.
1 parent 04bb22b commit d2f51b9

2 files changed

Lines changed: 529 additions & 2 deletions

File tree

crates/heartwood-nip46/src/server.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
// crates/heartwood-nip46/src/server.rs
22
//! Heartwood NIP-46 server state and request dispatcher.
33
4-
use std::collections::HashSet;
54
use std::sync::Mutex;
65

76
use heartwood_core::{
@@ -578,7 +577,7 @@ impl HeartwoodServer {
578577
/// It should not be called in production code.
579578
#[doc(hidden)]
580579
pub fn grant_all_permissions(&mut self, client_pubkey: &str) {
581-
let privileged: HashSet<String> = [
580+
let privileged: std::collections::HashSet<String> = [
582581
"heartwood_derive",
583582
"heartwood_derive_persona",
584583
"heartwood_switch",

0 commit comments

Comments
 (0)