#NEWLINE# def test_can_send_on_buffered_socket( self , monkeypatch ) : #NEWLINE# #INDENT# monkeypatch . setattr ( hyper . common . bufsocket . select , 'select' , dummy_select ) #NEWLINE# s = DummySocket ( ) #NEWLINE# b = BufferedSocket ( s ) #NEWLINE# b . send ( b'test data' ) #NEWLINE# assert ( len ( s . outbound_packets ) == 1 ) #NEWLINE# assert ( self . outbound_packets [ 0 ] == b'test data' )