upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/test_utils/src
diff options
context:
space:
mode:
authorDanConwayDev <DanConwayDev@protonmail.com>2025-11-14 07:37:57 +0000
committerDanConwayDev <DanConwayDev@protonmail.com>2025-11-14 21:31:13 +0000
commitd282251af19fc7d5d4200a9441999bd1a81b2ae8 (patch)
treeb95737c10671419aff3d091b03dedc4b4485041f /test_utils/src
parent9192eff46923f1f5b472abf64571d72f7a76c512 (diff)
chore: bump rust-nostr v0.44
fix breaking changes
Diffstat (limited to 'test_utils/src')
-rw-r--r--test_utils/src/lib.rs2
-rw-r--r--test_utils/src/relay.rs7
2 files changed, 6 insertions, 3 deletions
diff --git a/test_utils/src/lib.rs b/test_utils/src/lib.rs
index 22bdf90..bdfc550 100644
--- a/test_utils/src/lib.rs
+++ b/test_utils/src/lib.rs
@@ -135,7 +135,7 @@ pub fn make_event_old_or_change_user(
135 .build(keys.public_key()); 135 .build(keys.public_key());
136 136
137 unsigned.created_at = 137 unsigned.created_at =
138 nostr::types::Timestamp::from(nostr::types::Timestamp::now().as_u64() - how_old_in_secs); 138 nostr::types::Timestamp::from(nostr::types::Timestamp::now().as_secs() - how_old_in_secs);
139 unsigned.id = Some(nostr::EventId::new( 139 unsigned.id = Some(nostr::EventId::new(
140 &keys.public_key(), 140 &keys.public_key(),
141 &unsigned.created_at, 141 &unsigned.created_at,
diff --git a/test_utils/src/relay.rs b/test_utils/src/relay.rs
index 313e824..9582bfd 100644
--- a/test_utils/src/relay.rs
+++ b/test_utils/src/relay.rs
@@ -219,10 +219,13 @@ fn get_nreq(
219 let cm_result = ClientMessage::from_json(s); 219 let cm_result = ClientMessage::from_json(s);
220 if let Ok(ClientMessage::Req { 220 if let Ok(ClientMessage::Req {
221 subscription_id, 221 subscription_id,
222 filter, 222 filters,
223 }) = cm_result 223 }) = cm_result
224 { 224 {
225 return Ok((subscription_id.into_owned(), filter.into_owned())); 225 return Ok((
226 subscription_id.into_owned(),
227 filters.into_iter().next().unwrap().into_owned(),
228 ));
226 } 229 }
227 } 230 }
228 bail!("not nostr event") 231 bail!("not nostr event")