moved some functions from test_base.py into server_related.py