1 | from zope.interface import implements |
---|
2 | |
---|
3 | from kss.demo import KSSSeleniumTestSuite, KSSSeleniumTestDirectory, \ |
---|
4 | KSSSeleniumTestCase |
---|
5 | |
---|
6 | from plone.app.kss.demo.zopeconfig import PloneSiteLayer, \ |
---|
7 | LoggedInManagerLayer, LoggedInUserLayer, IResource |
---|
8 | |
---|
9 | |
---|
10 | # |
---|
11 | # XXX Important message to developers |
---|
12 | # |
---|
13 | # Dear Developer! Do _not_ use the setup you see below as an example |
---|
14 | # for your own programs, or otherwise you will need to change |
---|
15 | # it later. The test suite creation interface will change in |
---|
16 | # the next kss.demo versions. The plugin class (PloneDemos) |
---|
17 | # will change in the next major KSS (and possibly Plone) version. |
---|
18 | # This configuration file will be kept up-to-date to these changes. |
---|
19 | # |
---|
20 | # It is safe, however, to fix existing tests or drop new |
---|
21 | # tests in the directories set up below. |
---|
22 | # |
---|
23 | |
---|
24 | class PortalTabsLayer(LoggedInManagerLayer): |
---|
25 | setup = KSSSeleniumTestCase('install-tabs.html') |
---|
26 | teardown = KSSSeleniumTestCase('uninstall-tabs.html') |
---|
27 | |
---|
28 | |
---|
29 | class PloneTabsSeleniumKssTests(object): |
---|
30 | implements(IResource) |
---|
31 | |
---|
32 | demos = () |
---|
33 | |
---|
34 | selenium_tests = ( |
---|
35 | KSSSeleniumTestSuite( |
---|
36 | tests=KSSSeleniumTestDirectory('selenium_tests/' +\ |
---|
37 | 'run_as_testmanager'), |
---|
38 | layer=PortalTabsLayer, |
---|
39 | component='quintagroup.plonetabs', |
---|
40 | application='quintagroup.plonetabs', |
---|
41 | ), |
---|
42 | ) |
---|