fix for tests to pass under PyPy

tests were written wrong - server socket had need to be explicitly
closed. CPython's garbage collector took care of that, but PyPy couldn't