upleb.uk

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

summaryrefslogtreecommitdiff
path: root/test_utils/src/git.rs
diff options
context:
space:
mode:
Diffstat (limited to 'test_utils/src/git.rs')
-rw-r--r--test_utils/src/git.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/test_utils/src/git.rs b/test_utils/src/git.rs
index af87a3a..7f0b4c7 100644
--- a/test_utils/src/git.rs
+++ b/test_utils/src/git.rs
@@ -146,6 +146,11 @@ impl GitTestRepo {
146 .context(format!("cannot find branch {branch_name}"))?; 146 .context(format!("cannot find branch {branch_name}"))?;
147 Ok(branch.into_reference().peel_to_commit()?.id()) 147 Ok(branch.into_reference().peel_to_commit()?.id())
148 } 148 }
149
150 pub fn add_remote(&self, name: &str, url: &str) -> Result<()> {
151 self.git_repo.remote(name, url)?;
152 Ok(())
153 }
149} 154}
150 155
151impl Drop for GitTestRepo { 156impl Drop for GitTestRepo {