Why don't we abstract the port finding into the serverHelper so that we can clean up the test code a bit?