From 9e66f354dfbc27496eff5c47e3a1f774e66216f7 Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Wed, 23 Sep 2009 00:40:14 +0000 Subject: [PATCH] #2073: Adds a warning (about turning off undo, rather than filling with bogus data), but this is only seen by developers, and at least gives a chance to cancel; probably not worth a special class just to provide proper message svn: r13233 --- src/plugins/tool/TestcaseGenerator.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/plugins/tool/TestcaseGenerator.py b/src/plugins/tool/TestcaseGenerator.py index af9c11fd1..eaac8abb0 100644 --- a/src/plugins/tool/TestcaseGenerator.py +++ b/src/plugins/tool/TestcaseGenerator.py @@ -55,7 +55,7 @@ import LdsUtils # # #------------------------------------------------------------------------- -class TestcaseGenerator(Tool.Tool): +class TestcaseGenerator(Tool.BatchTool): NUMERIC = 0 FIRSTNAME = 1 FIRSTNAME_FEMALE = 2 @@ -69,7 +69,10 @@ class TestcaseGenerator(Tool.Tool): if dbstate.db.readonly: return - Tool.Tool.__init__(self, dbstate, options_class, name) + Tool.BatchTool.__init__(self, dbstate, options_class, name) + + if self.fail: + return self.person_count = 0 self.persons_todo = []