mirror of
https://github.com/zed-industries/zed.git
synced 2025-01-11 21:13:02 +00:00
Simulate server restarts in randomized test
This commit is contained in:
parent
f1884d608b
commit
a594ba8f8a
1 changed files with 7 additions and 0 deletions
|
@ -6121,6 +6121,13 @@ async fn test_random_collaboration(
|
|||
deterministic.advance_clock(RECEIVE_TIMEOUT + RECONNECT_TIMEOUT);
|
||||
operations += 1;
|
||||
}
|
||||
30..=34 => {
|
||||
log::info!("Simulating server restart");
|
||||
server.teardown();
|
||||
deterministic.advance_clock(RECEIVE_TIMEOUT + RECONNECT_TIMEOUT);
|
||||
server.start().await.unwrap();
|
||||
deterministic.advance_clock(RECONNECT_TIMEOUT);
|
||||
}
|
||||
_ if !op_start_signals.is_empty() => {
|
||||
while operations < max_operations && rng.lock().gen_bool(0.7) {
|
||||
op_start_signals
|
||||
|
|
Loading…
Reference in a new issue