tor-hsclient: Call the mock with the result circuit

This commit is contained in:
Ian Jackson 2023-06-08 16:29:24 +01:00
parent 90a48f5b52
commit 8e5814c683
1 changed files with 5 additions and 0 deletions

View File

@ -255,6 +255,7 @@ impl<'c, R: Runtime, M: MocksForConnect<R>> Context<'c, R, M> {
mocks.test_got_desc(desc);
let circ = self.intro_rend_connect(desc, &mut data.ipts).await?;
mocks.test_got_circ(&circ);
Ok(circ)
}
@ -730,6 +731,10 @@ trait MocksForConnect<R>: Clone {
fn test_got_desc(&self, desc: &HsDesc) {
eprintln!("HS DESC:\n{:?}\n", &desc); // TODO HS remove
}
/// Tell tests we got this circuit
fn test_got_circ(&self, circ: &Arc<ClientCirc>) {
eprintln!("HS CIRC:\n{:?}\n", &circ); // TODO HS remove
}
/// Return a random number generator
fn thread_rng(&self) -> Self::Rng;