diff testharness/src/bin/testharness.rs @ 167:0cabe7b94a4f

Check for old_authtok in change_authtok to emulate real behavior.
author Paul Fisher <paul@pfish.zone>
date Tue, 15 Jul 2025 00:39:08 -0400
parents 2f5913131295
children e27c5c667a5a
line wrap: on
line diff
--- a/testharness/src/bin/testharness.rs	Tue Jul 15 00:32:24 2025 -0400
+++ b/testharness/src/bin/testharness.rs	Tue Jul 15 00:39:08 2025 -0400
@@ -43,12 +43,16 @@
                 Exchange::MaskedPrompt(p) => {
                     let answer = if self.changing_password.get() {
                         let prompts = self.change_prompt_count.get();
+                        eprintln!("CHANGING PASSWORD PROMPT {prompts}");
+                        eprintln!("-> {p:?}");
                         self.change_prompt_count.set(prompts + 1);
                         match prompts {
-                            0 => "mistake",
-                            1 => "mismatch",
-                            2 => "acceptable",
-                            3 => "acceptable",
+                            0 => "old token!",
+                            1 => "mistake",
+                            2 => "mismatch",
+                            3 => "old token!",
+                            4 => "acceptable",
+                            5 => "acceptable",
                             _ => panic!("unexpected number of prompts!"),
                         }
                     } else if self.wrong_password {