#NEWLINE# def test_simple_game( self ) : #NEWLINE# #INDENT# layout = '\n        ##########\n        #        #\n        #0  ..  1#\n        ##########\n        ' #NEWLINE# server = SimpleServer ( layout_string = layout , rounds = 5 , players = 2 , bind_addrs = ( ( 'ipc:///tmp/pelita-testplayer1-%s' % uuid . uuid4 ( ) ) , ( 'ipc:///tmp/pelita-testplayer2-%s' % uuid . uuid4 ( ) ) ) ) #NEWLINE# for bind_address in server . bind_addresses : #NEWLINE# #INDENT# self . assertTrue ( bind_address . startswith ( 'ipc://' ) ) #NEWLINE# #UNINDENT# client1_address = server . bind_addresses [ 0 ] #NEWLINE# client2_address = server . bind_addresses [ 1 ] #NEWLINE# client1 = SimpleClient ( SimpleTeam ( 'team1' , RandomPlayer ( ) ) , address = client2_address ) #NEWLINE# client2 = SimpleClient ( SimpleTeam ( 'team2' , RandomPlayer ( ) ) , address = client2_address ) #NEWLINE# client1 . autoplay_process ( ) #NEWLINE# client2 . autoplay_process ( ) #NEWLINE# server . run ( ) #NEWLINE# server . shutdown ( )