source: geniuswebcore/test/geniusweb/partystdio/PartyStdioTest.py@ 94

Last change on this file since 94 was 90, checked in by Bart Vastenhouw, 3 years ago

Refactor to help reusing partiesserver.

File size: 1.2 KB
Line 
1import time
2import unittest
3
4from geniusweb.partystdio.PartyStdIo import PartyStdIo
5from test.geniusweb.partystdio.EmptyParty import EmptyParty
6
7
8class PartyStdIoTest(unittest.TestCase):
9
10
11
12 def testCapabilities(self):
13 channel = PartyStdIo(EmptyParty)
14 channel.capabilities()
15 # we really should check what is printed to stdout now...
16
17
18 def testDescription(self):
19 channel = PartyStdIo(EmptyParty)
20 channel.description()
21 # we really should check what is printed to stdout now...
22
23 '''
24 Test if the pipe to the party correctly converts incoming test
25 strings to objects
26 '''
27 #FIXME
28# def testPipe(self):
29# channel = PartyStdIo(EmptyParty)
30# r,w = os.pipe()
31# inpipe = os.fdopen(r)
32# outpipe=os.fdopen(w, 'w')
33#
34# thread = threading.Thread(target=lambda:channel.run(connend=inpipe))
35# thread.start()
36# time.sleep(0.5)
37# outpipe.write('nonsense')
38# thread.join(0.5)
39# os.close(inpipe)
40# os.close(outpipe)
41# self.assertFalse(thread.isAlive())
42
Note: See TracBrowser for help on using the repository browser.