Skip to content

Commit 0040a24

Browse files
test(cli): Fix poll cert being too fast
Sometime `rexpect` is too slow to see `poll server` line and timeout instead, so we just ignore the result instead and continue as normal.
1 parent 83f274c commit 0040a24

File tree

3 files changed

+3
-9
lines changed

3 files changed

+3
-9
lines changed

cli/tests/integration/invitations/device.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,7 @@ async fn invite_device_dance(tmp_path: TmpPath) {
8989

9090
locked.exp_string("Enter password for the device:").unwrap();
9191
locked.send_line(DEFAULT_DEVICE_PASSWORD).unwrap();
92-
locked
93-
.exp_string("Poll server for new certificates")
94-
.unwrap();
92+
let _ = locked.exp_string("Poll server for new certificates");
9593
locked.exp_string("Waiting for claimer").unwrap();
9694
});
9795
let claimer_cloned = p_claimer.clone();

cli/tests/integration/invitations/shared_recovery.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,7 @@ async fn invite_shared_recovery_dance(tmp_path: TmpPath) {
9797

9898
locked.exp_string("Enter password for the device:").unwrap();
9999
locked.send_line(DEFAULT_DEVICE_PASSWORD).unwrap();
100-
locked
101-
.exp_string("Poll server for new certificates")
102-
.unwrap();
100+
let _ = locked.exp_string("Poll server for new certificates");
103101
locked.exp_string("Waiting for claimer").unwrap();
104102
});
105103
let claimer_cloned = p_claimer.clone();

cli/tests/integration/invitations/user.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,7 @@ async fn invite_user_dance(tmp_path: TmpPath) {
102102

103103
locked.exp_string("Enter password for the device:").unwrap();
104104
locked.send_line(DEFAULT_DEVICE_PASSWORD).unwrap();
105-
locked
106-
.exp_string("Poll server for new certificates")
107-
.unwrap();
105+
let _ = locked.exp_string("Poll server for new certificates");
108106
locked.exp_string("Waiting for claimer").unwrap();
109107
});
110108
let claimer_cloned = p_claimer.clone();

0 commit comments

Comments
 (0)