Commit 51a24eff authored by Łukasz Nowak's avatar Łukasz Nowak

- assert that provided software is runable


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@36163 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 97296bfd
......@@ -115,6 +115,25 @@ class AssertLddLibs(unittest.TestCase):
result = os.system("ldd parts/memcached/bin/memcached | grep -q 'parts/li"
"bevent/lib/libevent'")
class AssertSoftwareRunable(unittest.TestCase):
def test_HaProxy(self):
stdout, stderr = subprocess.Popen(["parts/haproxy/sbin/haproxy", "-v"],
stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()
self.assertEqual(stderr, '')
self.assertTrue(stdout.startswith('HA-Proxy'))
def test_Apache(self):
stdout, stderr = subprocess.Popen(["parts/apache/bin/httpd", "-v"],
stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()
self.assertEqual(stderr, '')
self.assertTrue(stdout.startswith('Server version: Apache'))
def test_Ocropus(self):
stdout, stderr = subprocess.Popen(["parts/ocropus/bin/ocropus"],
stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()
self.assertEqual(stdout, '')
self.assertTrue('splitting books' in stderr)
class AssertApache(unittest.TestCase):
"""Tests for built apache"""
......
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