forked from goodboy/tractor
				
			Avoid infinite wait for EOF
							parent
							
								
									a4bac135d9
								
							
						
					
					
						commit
						457499bc2e
					
				| 
						 | 
					@ -737,7 +737,7 @@ def test_root_nursery_cancels_before_child_releases_tty_lock(
 | 
				
			||||||
        child.sendline('c')
 | 
					        child.sendline('c')
 | 
				
			||||||
        time.sleep(0.1)
 | 
					        time.sleep(0.1)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    while True:
 | 
					    for i in range(10):
 | 
				
			||||||
        try:
 | 
					        try:
 | 
				
			||||||
            child.expect(pexpect.EOF)
 | 
					            child.expect(pexpect.EOF)
 | 
				
			||||||
            break
 | 
					            break
 | 
				
			||||||
| 
						 | 
					@ -745,6 +745,9 @@ def test_root_nursery_cancels_before_child_releases_tty_lock(
 | 
				
			||||||
            child.sendline('c')
 | 
					            child.sendline('c')
 | 
				
			||||||
            time.sleep(0.1)
 | 
					            time.sleep(0.1)
 | 
				
			||||||
            print('child was able to grab tty lock again?')
 | 
					            print('child was able to grab tty lock again?')
 | 
				
			||||||
 | 
					    else:
 | 
				
			||||||
 | 
					        child.sendline('q')
 | 
				
			||||||
 | 
					        child.expect(pexpect.EOF)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if not timed_out_early:
 | 
					    if not timed_out_early:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue