+++ /dev/null
-# Copyright (C) 2003 Python Software Foundation\r
-\r
-import unittest\r
-from test import test_support\r
-\r
-# Skip this test if aetools does not exist.\r
-test_support.import_module('aetools')\r
-\r
-class TestScriptpackages(unittest.TestCase):\r
-\r
- def _test_scriptpackage(self, package, testobject=1):\r
- # Check that we can import the package\r
- mod = __import__(package)\r
- # Test that we can get the main event class\r
- klass = getattr(mod, package)\r
- # Test that we can instantiate that class\r
- talker = klass()\r
- if testobject:\r
- # Test that we can get an application object\r
- obj = mod.application(0)\r
-\r
- def test__builtinSuites(self):\r
- self._test_scriptpackage('_builtinSuites', testobject=0)\r
-\r
- def test_StdSuites(self):\r
- self._test_scriptpackage('StdSuites')\r
-\r
- def test_SystemEvents(self):\r
- self._test_scriptpackage('SystemEvents')\r
-\r
- def test_Finder(self):\r
- self._test_scriptpackage('Finder')\r
-\r
- def test_Terminal(self):\r
- self._test_scriptpackage('Terminal')\r
-\r
- def test_Netscape(self):\r
- self._test_scriptpackage('Netscape')\r
-\r
- def test_Explorer(self):\r
- self._test_scriptpackage('Explorer')\r
-\r
- def test_CodeWarrior(self):\r
- self._test_scriptpackage('CodeWarrior')\r
-\r
-def test_main():\r
- test_support.run_unittest(TestScriptpackages)\r
-\r
-\r
-if __name__ == '__main__':\r
- test_main()\r