Remove extra expect (paste error) that broke bootAndRunTests()

This commit is contained in:
Bob Lantz
2013-09-17 18:02:06 -07:00
parent 811963ad26
commit 4ccfe242e8
+1 -3
View File
@@ -744,7 +744,7 @@ def getMininetVersion( vm ):
return version return version
def bootAndRunTests( image, tests=None ): def bootAndRunTests( image, tests=None, prompt=Prompt ):
"""Boot and test VM """Boot and test VM
tests: list of tests (default: sanity, core)""" tests: list of tests (default: sanity, core)"""
bootTestStart = time() bootTestStart = time()
@@ -764,14 +764,12 @@ def bootAndRunTests( image, tests=None ):
suffix='.testlog', delete=False ) suffix='.testlog', delete=False )
log( '* Logging VM output to', logfile.name ) log( '* Logging VM output to', logfile.name )
vm = boot( cow=cow, kernel=kernel, initrd=initrd, logfile=logfile ) vm = boot( cow=cow, kernel=kernel, initrd=initrd, logfile=logfile )
prompt = '\$ '
login( vm ) login( vm )
log( '* Waiting for prompt after login' ) log( '* Waiting for prompt after login' )
vm.expect( prompt ) vm.expect( prompt )
if Branch: if Branch:
checkOutBranch( vm, branch=Branch ) checkOutBranch( vm, branch=Branch )
vm.expect( prompt ) vm.expect( prompt )
vm.expect( prompt )
log( '* Running tests' ) log( '* Running tests' )
runTests( vm, tests=tests ) runTests( vm, tests=tests )
# runTests eats its last prompt, but maybe it shouldn't... # runTests eats its last prompt, but maybe it shouldn't...