r16440 - gnucash/branches/dogtail/src/test-dogtail - test add new account wizard test case added

Ahmed Sayed asayed at cvs.gnucash.org
Thu Aug 16 18:05:54 EDT 2007


Author: asayed
Date: 2007-08-16 18:05:53 -0400 (Thu, 16 Aug 2007)
New Revision: 16440
Trac: http://svn.gnucash.org/trac/changeset/16440

Modified:
   gnucash/branches/dogtail/src/test-dogtail/runtest.py
Log:
test add new account wizard test case added


Modified: gnucash/branches/dogtail/src/test-dogtail/runtest.py
===================================================================
--- gnucash/branches/dogtail/src/test-dogtail/runtest.py	2007-08-16 22:05:14 UTC (rev 16439)
+++ gnucash/branches/dogtail/src/test-dogtail/runtest.py	2007-08-16 22:05:53 UTC (rev 16440)
@@ -527,8 +527,40 @@
 
 class TestWizard(unittest.TestCase):
     """ Will be a scenarios will walk throw different pathes of the wizads """
-    pass
+    def setUp(self):
+        cleanup_all()
+        run('gnucash')
+        sleep(20)
+        gnuCash = GnuCashApp()
+        gnuCash.dismiss_all_dialogs()
 
+    def tearDown(self):
+        gnuCash = GnuCashApp()
+        gnuCash.close_without_saving()
+
+    def test_default_wizard(self):
+        """ Test Only the default wizards """
+        gnucash = GnuCashApp()
+        gnucash.menu('File').menu('New').menuItem('New File').click()
+
+        focus.application('gnucash')
+        click('Continue Without Saving', roleName='push button')
+
+        duride_frame = gnucash.findChild(\
+        predicate.GenericPredicate(roleName='frame', \
+        name='New Account Hierarchy Setup'))
+        new_account_setup = NewAccountSetup(duride_frame)
+        new_account_setup.clickForward()
+        new_account_setup.clickForward()
+        new_account_setup.clickForward()
+        new_account_setup.clickForward()
+        new_account_setup.clickApply()
+
+        # Validation
+        account_tab = gnucash.tab('Accounts')
+        self.assertEquals(validate_node(account_tab, 'test_default_wizard'), EXIT_SUCCESS)
+
+
 class TestPreferences(unittest.TestCase):
     """  Will be a set of scenarios that will detect the affet of changing preferences """
     pass



More information about the gnucash-changes mailing list