mirror of
https://github.com/D-Modem/app.git
synced 2026-11-28 17:38:05 -08:00
PppHostTest: wait for the host's side of the link to come up (it may follow the computer's)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0172Hejd12i4aYikYW9vgpZs
This commit is contained in:
1 file changed
+3
@@ -106,6 +106,9 @@ class PppHostTest {
|
||||
val cfg = c.startPpp()
|
||||
assertEquals("10.64.64.2", cfg.address.hostAddress)
|
||||
assertEquals(listOf("10.64.64.1"), cfg.dns.map { it.hostAddress })
|
||||
// (the host's side of the link up too: a moment after the computer's, perhaps)
|
||||
val end = System.currentTimeMillis() + 3000
|
||||
while (!c.host.online.value && System.currentTimeMillis() < end) Thread.sleep(10)
|
||||
assertTrue(c.host.online.value)
|
||||
// the computer hangs up (DTR): NO CARRIER, and commands again
|
||||
c.pppOn = false
|
||||
|
||||
Reference in new issue
Block a user