diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2025-07-16 10:10:41 +0100 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2025-07-16 10:39:35 +0100 |
| commit | 092b9606ff2b721d858a5c7b2b27a2f9942b4bc4 (patch) | |
| tree | 29022aee83ac0460098dfdbd4362ef75388c4ea7 /test_utils/src | |
| parent | 6e041a3626f04e591d5c22f71d3e4ab2b03bd7bb (diff) | |
chore: nix flake update
required running:
`cargo fix --allow-dirty --allow-staged`
`cargo clippy --fix --allow-dirty -- -D warnings`
to fix problems
and then manually fixing some too
Diffstat (limited to 'test_utils/src')
| -rw-r--r-- | test_utils/src/lib.rs | 10 | ||||
| -rw-r--r-- | test_utils/src/relay.rs | 2 |
2 files changed, 6 insertions, 6 deletions
diff --git a/test_utils/src/lib.rs b/test_utils/src/lib.rs index 5feb64b..1312610 100644 --- a/test_utils/src/lib.rs +++ b/test_utils/src/lib.rs | |||
| @@ -167,7 +167,7 @@ pub fn generate_repo_ref_event_with_git_server_with_keys( | |||
| 167 | .tags([ | 167 | .tags([ |
| 168 | Tag::identifier( | 168 | Tag::identifier( |
| 169 | // root_commit.to_string() | 169 | // root_commit.to_string() |
| 170 | format!("{}-consider-it-random", root_commit), | 170 | format!("{root_commit}-consider-it-random"), |
| 171 | ), | 171 | ), |
| 172 | Tag::from_standardized(TagStandard::Reference(root_commit.to_string())), | 172 | Tag::from_standardized(TagStandard::Reference(root_commit.to_string())), |
| 173 | Tag::from_standardized(TagStandard::Name("example name".into())), | 173 | Tag::from_standardized(TagStandard::Name("example name".into())), |
| @@ -1235,10 +1235,10 @@ pub fn create_and_populate_branch( | |||
| 1235 | test_repo.checkout("main")?; | 1235 | test_repo.checkout("main")?; |
| 1236 | test_repo.create_branch(branch_name)?; | 1236 | test_repo.create_branch(branch_name)?; |
| 1237 | test_repo.checkout(branch_name)?; | 1237 | test_repo.checkout(branch_name)?; |
| 1238 | let file_name = format!("{}3.md", prefix); | 1238 | let file_name = format!("{prefix}3.md"); |
| 1239 | std::fs::write(test_repo.dir.join(&file_name), "some content")?; | 1239 | std::fs::write(test_repo.dir.join(&file_name), "some content")?; |
| 1240 | test_repo.stage_and_commit_custom_signature( | 1240 | test_repo.stage_and_commit_custom_signature( |
| 1241 | &format!("add {}3.md", prefix), | 1241 | &format!("add {prefix}3.md"), |
| 1242 | Some( | 1242 | Some( |
| 1243 | &Signature::new( | 1243 | &Signature::new( |
| 1244 | "Joe Bloggs", | 1244 | "Joe Bloggs", |
| @@ -1250,10 +1250,10 @@ pub fn create_and_populate_branch( | |||
| 1250 | commiter, | 1250 | commiter, |
| 1251 | )?; | 1251 | )?; |
| 1252 | if !only_one_commit { | 1252 | if !only_one_commit { |
| 1253 | let file_name = format!("{}4.md", prefix); | 1253 | let file_name = format!("{prefix}4.md"); |
| 1254 | std::fs::write(test_repo.dir.join(&file_name), "some content")?; | 1254 | std::fs::write(test_repo.dir.join(&file_name), "some content")?; |
| 1255 | test_repo.stage_and_commit_custom_signature( | 1255 | test_repo.stage_and_commit_custom_signature( |
| 1256 | &format!("add {}4.md", prefix), | 1256 | &format!("add {prefix}4.md"), |
| 1257 | Some( | 1257 | Some( |
| 1258 | &Signature::new( | 1258 | &Signature::new( |
| 1259 | "Joe Bloggs", | 1259 | "Joe Bloggs", |
diff --git a/test_utils/src/relay.rs b/test_utils/src/relay.rs index e820651..14778d9 100644 --- a/test_utils/src/relay.rs +++ b/test_utils/src/relay.rs | |||
| @@ -186,7 +186,7 @@ impl<'a> Relay<'a> { | |||
| 186 | 186 | ||
| 187 | pub fn shutdown_relay(port: u64) -> Result<()> { | 187 | pub fn shutdown_relay(port: u64) -> Result<()> { |
| 188 | let mut counter = 0; | 188 | let mut counter = 0; |
| 189 | while let Ok((mut socket, _)) = tungstenite::connect(format!("ws://localhost:{}", port)) { | 189 | while let Ok((mut socket, _)) = tungstenite::connect(format!("ws://localhost:{port}")) { |
| 190 | counter += 1; | 190 | counter += 1; |
| 191 | if counter == 1 { | 191 | if counter == 1 { |
| 192 | socket.write(tungstenite::Message::text("shut me down"))?; | 192 | socket.write(tungstenite::Message::text("shut me down"))?; |