circmgr: Split request_timeout test into two.

There seems to be some issue here with the new WaitFor code,
where using the same MockSleepProvider with both of these wait_for()
calls gives questionable behavior under some circumstances (like
when running under Tarpaulin with the wrong set of flags).
This commit is contained in:
Nick Mathewson 2021-10-26 13:01:13 -04:00
parent b0fd7cff8e
commit c6a1bcaa69
1 changed files with 7 additions and 0 deletions

View File

@ -1436,6 +1436,13 @@ mod test {
.await; .await;
assert!(matches!(c1, Err(Error::RequestFailed(_)))); assert!(matches!(c1, Err(Error::RequestFailed(_))));
});
}
#[test]
fn request_timeout2() {
tor_rtcompat::test_with_one_runtime!(|rt| async {
let rt = MockSleepRuntime::new(rt);
// Now try a more complicated case: we'll try to get things so // Now try a more complicated case: we'll try to get things so
// that we wait for a little over our predicted time because // that we wait for a little over our predicted time because