Permalink
Browse files

Rename a few things from server to tcp_server.

  • Loading branch information...
Auke Willem Oosterhoff
Auke Willem Oosterhoff committed Jul 29, 2016
1 parent 6e11a74 commit 2ccefe3d52a508385e2f60fbcf954d25f5516b25
@@ -3,22 +3,22 @@
import socket
from threading import Thread
from .server import app
from .rtu import app as rtu
from .tcp_server import app as tcp
from .rtu_server import app as rtu
@pytest.fixture(autouse=True, scope="session")
def tcp_server(request):
t = Thread(target=app.serve_forever)
t = Thread(target=tcp.serve_forever)
t.start()
def fin():
app.shutdown()
app.server_close()
tcp.shutdown()
tcp.server_close()
t.join()
request.addfinalizer(fin)
return app
return tcp
@pytest.yield_fixture
File renamed without changes.
File renamed without changes.
@@ -3,4 +3,4 @@
class test_rtu_server_create_response_adu():
server = RTUServer()
assert server.create_response_adu({'unit_id': 1}, b'') == \ b'\x01~\x80'
assert server.create_response_adu({'unit_id': 1}, b'') == b'\x01~\x80'

0 comments on commit 2ccefe3

Please sign in to comment.