[th/test-client-fixes] fix test-client.py test
The test doesn't work with python2, which breaks copr builds (against epel7). Fix that (by skipping the test).
Also, fix a leak warning.
Also, don't do os.dup2(s.fileno(), 3)
, when we can just pass the original FD on.