[Checkins] SVN: zc.selenium/branches/wosc-zope2/src/zc/selenium/selenium.py stop zope2 upon Ctrl-C, too
Wolfgang Schnerring
wosc at wosc.de
Wed Feb 18 05:03:24 EST 2009
Log message for revision 96688:
stop zope2 upon Ctrl-C, too
Changed:
U zc.selenium/branches/wosc-zope2/src/zc/selenium/selenium.py
-=-
Modified: zc.selenium/branches/wosc-zope2/src/zc/selenium/selenium.py
===================================================================
--- zc.selenium/branches/wosc-zope2/src/zc/selenium/selenium.py 2009-02-18 09:52:31 UTC (rev 96687)
+++ zc.selenium/branches/wosc-zope2/src/zc/selenium/selenium.py 2009-02-18 10:03:24 UTC (rev 96688)
@@ -270,12 +270,14 @@
if options.keep_running or not options.auto_start:
while True:
- time.sleep(10000)
- else:
- if options.runner == 'zope2':
- stop_zope2(options.config, options.port)
- # exit with 0 if all tests passed, 1 if any failed
- sys.exit(not test_result)
+ try:
+ time.sleep(10000)
+ except KeyboardInterrupt:
+ break
+ if options.runner == 'zope2':
+ stop_zope2(options.config, options.port)
+ # exit with 0 if all tests passed, 1 if any failed
+ sys.exit(not test_result)
if __name__ == '__main__':
main()
More information about the Checkins
mailing list