--- a/tests/tools/conftest.py Fri Sep 15 19:45:41 2017 +0300
+++ b/tests/tools/conftest.py Fri Sep 15 19:51:31 2017 +0300
@@ -49,7 +49,7 @@
# To avoid this Xvfb is launched and killed not by pytest.
# $ Xvfb :42 -screen 0 1280x1024x24 &
-# $ pytest --timeout=10 ./tests/tools
+# $ pytest --timeout=10 ./tests/tools # TODO: find root of this problem.
--- a/tests/tools/test_application.py Fri Sep 15 19:45:41 2017 +0300
+++ b/tests/tools/test_application.py Fri Sep 15 19:51:31 2017 +0300
@@ -25,9 +25,11 @@
@@ -50,6 +52,9 @@
if self.app is not None and self.app.frame is not None:
@@ -71,6 +76,7 @@
class BeremizApplicationTest(UserApplicationTest):
"""Test Beremiz as whole application"""
@@ -102,7 +108,9 @@
item = self.app.frame.ProjectTree.GetNextVisible(item)
- def CheckTestProject(self, project):
+ def CheckTestProject(self, name): + project = self.GetProjectPath(name) + print "Testing example " + name self.OpenAllProjectElements()
@@ -130,23 +138,19 @@
- def testOpenExampleProjects(self):
- """Opens, builds and runs user PLC examples from tests directory"""
- project = self.GetProjectPath(name)
- print "Testing example " + name
- self.CheckTestProject(project)
+ @pytest.mark.timeout(30) + def testCheckProject(self, name): + self.CheckTestProject(name) if __name__ == '__main__':