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-10-17 15:22:05 +0100
committerDanConwayDev <DanConwayDev@protonmail.com>2025-10-17 17:18:47 +0100
commit4a9dcc66ac7be69031a19f6ece0be4642e1f3057 (patch)
tree3871a84a488c38d44b87658554354e345ebfee0f /test_utils/src
parentd35a007e92f57a55948a1b503d85f487bf771ac0 (diff)
chore: nix flake update
update nix dependancies including hardcoded nightly.rustfmt applied autofixes
Diffstat (limited to 'test_utils/src')
-rw-r--r--test_utils/src/git.rs2
-rw-r--r--test_utils/src/lib.rs22
-rw-r--r--test_utils/src/relay.rs2
3 files changed, 13 insertions, 13 deletions
diff --git a/test_utils/src/git.rs b/test_utils/src/git.rs
index 5942a54..ab21f38 100644
--- a/test_utils/src/git.rs
+++ b/test_utils/src/git.rs
@@ -216,7 +216,7 @@ impl GitTestRepo {
216 Ok(oid) 216 Ok(oid)
217 } 217 }
218 218
219 pub fn create_branch(&self, branch_name: &str) -> Result<Branch> { 219 pub fn create_branch(&'_ self, branch_name: &str) -> Result<Branch<'_>> {
220 self.git_repo 220 self.git_repo
221 .branch(branch_name, &self.git_repo.head()?.peel_to_commit()?, false) 221 .branch(branch_name, &self.git_repo.head()?.peel_to_commit()?, false)
222 .context("could not create branch") 222 .context("could not create branch")
diff --git a/test_utils/src/lib.rs b/test_utils/src/lib.rs
index 8d81efe..22bdf90 100644
--- a/test_utils/src/lib.rs
+++ b/test_utils/src/lib.rs
@@ -225,7 +225,7 @@ pub struct CliTester {
225} 225}
226 226
227impl CliTester { 227impl CliTester {
228 pub fn expect_input(&mut self, prompt: &str) -> Result<CliTesterInputPrompt> { 228 pub fn expect_input(&'_ mut self, prompt: &str) -> Result<CliTesterInputPrompt<'_>> {
229 let mut i = CliTesterInputPrompt { 229 let mut i = CliTesterInputPrompt {
230 tester: self, 230 tester: self,
231 prompt: prompt.to_string(), 231 prompt: prompt.to_string(),
@@ -234,7 +234,7 @@ impl CliTester {
234 Ok(i) 234 Ok(i)
235 } 235 }
236 236
237 pub fn expect_input_eventually(&mut self, prompt: &str) -> Result<CliTesterInputPrompt> { 237 pub fn expect_input_eventually(&'_ mut self, prompt: &str) -> Result<CliTesterInputPrompt<'_>> {
238 let mut i = CliTesterInputPrompt { 238 let mut i = CliTesterInputPrompt {
239 tester: self, 239 tester: self,
240 prompt: prompt.to_string(), 240 prompt: prompt.to_string(),
@@ -243,7 +243,7 @@ impl CliTester {
243 Ok(i) 243 Ok(i)
244 } 244 }
245 245
246 pub fn expect_password(&mut self, prompt: &str) -> Result<CliTesterPasswordPrompt> { 246 pub fn expect_password(&'_ mut self, prompt: &str) -> Result<CliTesterPasswordPrompt<'_>> {
247 let mut i = CliTesterPasswordPrompt { 247 let mut i = CliTesterPasswordPrompt {
248 tester: self, 248 tester: self,
249 prompt: prompt.to_string(), 249 prompt: prompt.to_string(),
@@ -254,10 +254,10 @@ impl CliTester {
254 } 254 }
255 255
256 pub fn expect_confirm( 256 pub fn expect_confirm(
257 &mut self, 257 &'_ mut self,
258 prompt: &str, 258 prompt: &str,
259 default: Option<bool>, 259 default: Option<bool>,
260 ) -> Result<CliTesterConfirmPrompt> { 260 ) -> Result<CliTesterConfirmPrompt<'_>> {
261 let mut i = CliTesterConfirmPrompt { 261 let mut i = CliTesterConfirmPrompt {
262 tester: self, 262 tester: self,
263 prompt: prompt.to_string(), 263 prompt: prompt.to_string(),
@@ -268,10 +268,10 @@ impl CliTester {
268 } 268 }
269 269
270 pub fn expect_confirm_eventually( 270 pub fn expect_confirm_eventually(
271 &mut self, 271 &'_ mut self,
272 prompt: &str, 272 prompt: &str,
273 default: Option<bool>, 273 default: Option<bool>,
274 ) -> Result<CliTesterConfirmPrompt> { 274 ) -> Result<CliTesterConfirmPrompt<'_>> {
275 let mut i = CliTesterConfirmPrompt { 275 let mut i = CliTesterConfirmPrompt {
276 tester: self, 276 tester: self,
277 prompt: prompt.to_string(), 277 prompt: prompt.to_string(),
@@ -282,10 +282,10 @@ impl CliTester {
282 } 282 }
283 283
284 pub fn expect_choice( 284 pub fn expect_choice(
285 &mut self, 285 &'_ mut self,
286 prompt: &str, 286 prompt: &str,
287 choices: Vec<String>, 287 choices: Vec<String>,
288 ) -> Result<CliTesterChoicePrompt> { 288 ) -> Result<CliTesterChoicePrompt<'_>> {
289 let mut i = CliTesterChoicePrompt { 289 let mut i = CliTesterChoicePrompt {
290 tester: self, 290 tester: self,
291 prompt: prompt.to_string(), 291 prompt: prompt.to_string(),
@@ -296,10 +296,10 @@ impl CliTester {
296 } 296 }
297 297
298 pub fn expect_multi_select( 298 pub fn expect_multi_select(
299 &mut self, 299 &'_ mut self,
300 prompt: &str, 300 prompt: &str,
301 choices: Vec<String>, 301 choices: Vec<String>,
302 ) -> Result<CliTesterMultiSelectPrompt> { 302 ) -> Result<CliTesterMultiSelectPrompt<'_>> {
303 let mut i = CliTesterMultiSelectPrompt { 303 let mut i = CliTesterMultiSelectPrompt {
304 tester: self, 304 tester: self,
305 prompt: prompt.to_string(), 305 prompt: prompt.to_string(),
diff --git a/test_utils/src/relay.rs b/test_utils/src/relay.rs
index 8a982a4..313e824 100644
--- a/test_utils/src/relay.rs
+++ b/test_utils/src/relay.rs
@@ -168,7 +168,7 @@ impl<'a> Relay<'a> {
168 self.respond_standard_req( 168 self.respond_standard_req(
169 client_id, 169 client_id,
170 &subscription_id, 170 &subscription_id,
171 &[filter.clone()], 171 std::slice::from_ref(&filter),
172 )?; 172 )?;
173 // self.respond_eose(client_id, subscription_id)?; 173 // self.respond_eose(client_id, subscription_id)?;
174 } 174 }