Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions noq-proto/proptest-regressions/tests/proptests.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,4 @@ cc 91184c7b6b718961d2dc03365f02098a18ac0035ca85b95654fbafa430d93664 # shrinks to
cc ec5baef3027436b012a332a97d46814ed157f259337c3f651bbb7a3233bd9c7f # shrinks to input = _RandomInteractionWithMultipathSimpleRoutingArgs { seed: [121, 74, 209, 215, 123, 149, 7, 227, 67, 200, 91, 12, 216, 81, 208, 77, 83, 181, 39, 2, 207, 186, 233, 211, 254, 178, 230, 22, 100, 197, 215, 43], interactions: [Drive { side: Client }, ClosePath { side: Client, path_idx: 0, error_code: 0 }] }
cc b1429b84bf576bb9000e8d0d6d53cff4c93efacf033c9df898aeb9856d1b03fe # shrinks to input = _RandomInteractionWithMultipathSimpleRoutingArgs { seed: [159, 14, 107, 252, 130, 4, 190, 131, 86, 208, 127, 29, 140, 30, 55, 65, 242, 192, 2, 158, 40, 51, 110, 116, 46, 139, 156, 165, 64, 109, 33, 62], interactions: [PassiveMigration { side: Server, addr_idx: 0 }, OpenPath { side: Client, status: Available, addr_idx: 0 }] }
cc 4f717acb71d562f33601dfc8c7fbcca89b13c8259676a20ffc764a92e3ea07a1 # shrinks to input = _RandomInteractionWithMultipathComplexRoutingArgs { seed: [84, 97, 201, 172, 244, 139, 252, 60, 222, 107, 135, 245, 103, 45, 188, 138, 26, 198, 1, 97, 144, 22, 42, 228, 19, 154, 45, 135, 222, 137, 231, 16], interactions: [PassiveMigration { side: Server, addr_idx: 0 }, OpenPath { side: Client, status: Available, addr_idx: 0 }, ClosePath { side: Client, path_idx: 0, error_code: 0 }, PathSetStatus { side: Server, path_idx: 0, status: Backup }], routes: RoutingTable { client_routes: [([::ffff:1.1.1.0]:44433, 0)], server_routes: [([::ffff:2.2.2.0]:4433, 0)] } }
cc 9c8a45ade151832ae26ea86bb672ff78e0ea55444c6e7fd51db202f255b6f616
62 changes: 62 additions & 0 deletions noq-proto/src/tests/proptests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1201,3 +1201,65 @@ fn regression_qnt_revalidating_path_forever() {
pair.server_conn_mut(server_ch)
)));
}

#[test]
fn regression_challenge_resend_loop() {
let prefix = "regression_challenge_resend_loop";
let setup = PairSetup {
seed: Seed::Zeroes,
extensions: Extensions::MultipathOnly,
routing_setup: RoutingSetup::Complex(RoutingTable::from_routes(
vec![("[::ffff:1.1.1.0]:44433".parse().unwrap(), 0)],
vec![
("[::ffff:2.2.2.0]:4433".parse().unwrap(), 0),
("[::ffff:2.2.2.1]:4433".parse().unwrap(), 0),
],
)),
};
let interactions = vec![
TestOp::OpenPath {
side: Side::Client,
status: PathStatus::Available,
addr_idx: 0,
},
TestOp::Drive { side: Side::Client },
TestOp::OpenPath {
side: Side::Client,
status: PathStatus::Available,
addr_idx: 1,
},
TestOp::DropInbound { side: Side::Client },
TestOp::Drive { side: Side::Client },
TestOp::AdvanceTime,
TestOp::Drive { side: Side::Server },
TestOp::OpenPath {
side: Side::Client,
status: PathStatus::Available,
addr_idx: 1,
},
TestOp::OpenPath {
side: Side::Client,
status: PathStatus::Available,
addr_idx: 0,
},
TestOp::Drive { side: Side::Client },
TestOp::OpenPath {
side: Side::Client,
status: PathStatus::Available,
addr_idx: 1,
},
TestOp::AdvanceTime,
];

let _guard = subscribe();
let (mut pair, client_config) = setup.run(prefix);
let (client_ch, server_ch) = run_random_interaction(&mut pair, interactions, client_config);

assert!(!pair.drive_bounded(1000), "connection never became idle");
assert!(allowed_error(poll_to_close(
pair.client_conn_mut(client_ch)
)));
assert!(allowed_error(poll_to_close(
pair.server_conn_mut(server_ch)
)));
}
Loading