blob: f05dc5d0703feb5df053d7c658bd22bd6d563f63 [file] [log] [blame]
Mark Slee5299a952007-10-05 00:13:24 +00001#!/usr/bin/env python
2
3import subprocess
4import sys
5import os
6import signal
7
David Reiss2a4bfd62008-04-07 23:45:00 +00008def relfile(fname):
9 return os.path.join(os.path.dirname(__file__), fname)
10
11serverproc = subprocess.Popen([sys.executable, relfile("TestServer.py")])
Mark Slee5299a952007-10-05 00:13:24 +000012try:
David Reiss0c90f6f2008-02-06 22:18:40 +000013
David Reiss2a4bfd62008-04-07 23:45:00 +000014 ret = subprocess.call([sys.executable, relfile("TestClient.py")])
Mark Slee5299a952007-10-05 00:13:24 +000015 if ret != 0:
16 raise Exception("subprocess failed")
17finally:
18 # fixme: should check that server didn't die
19 os.kill(serverproc.pid, signal.SIGKILL)