Commit d2d5c4ec authored by Ivan Tyagov's avatar Ivan Tyagov

Add test to check Skin selection removal when bt5 which registered it has ben uninstalled.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@24717 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 1a03f0e0
...@@ -5206,6 +5206,40 @@ class TestBusinessTemplate(ERP5TypeTestCase, LogInterceptor): ...@@ -5206,6 +5206,40 @@ class TestBusinessTemplate(ERP5TypeTestCase, LogInterceptor):
sequence_list.addSequenceString(sequence_string) sequence_list.addSequenceString(sequence_string)
sequence_list.play(self, quiet=quiet) sequence_list.play(self, quiet=quiet)
def test_158_BusinessTemplateSkinSelectionRemoveWhenUninstalled(self, quiet=quiet,
run=run_all_test):
if not run: return
if not quiet:
message = 'Test Business Template Uninstall With Skin Selection'
ZopeTestCase._print('\n%s ' % message)
LOG('Testing... ', 0, message)
sequence_list = SequenceList()
sequence_string = 'CreateSkinFolder \
SetSkinFolderRegistredSelections \
CreateNewBusinessTemplate \
UseExportBusinessTemplate \
AddSkinFolderToBusinessTemplate \
BuildBusinessTemplate \
SaveBusinessTemplate \
RemoveSkinFolder \
ImportBusinessTemplate \
UseImportBusinessTemplate \
InstallBusinessTemplate \
Tic \
CheckSkinSelectionAdded \
stepUninstallBusinessTemplate \
stepCheckSkinSelectionRemoved \
'
sequence_list.addSequenceString(sequence_string)
sequence_list.play(self, quiet=quiet)
def stepCheckSkinSelectionRemoved(self, sequence=None, sequence_list=None, **kw):
"""
Check that a skin selection has been removed.
"""
self.failUnless('Foo' not in self.portal.portal_skins._getSelections().keys())
def test_suite(): def test_suite():
suite = unittest.TestSuite() suite = unittest.TestSuite()
suite.addTest(unittest.makeSuite(TestBusinessTemplate)) suite.addTest(unittest.makeSuite(TestBusinessTemplate))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment