Fixed broken tests after Mojolicious 5.0

Some tests were broken as Mojo::IOLoop->generate_port has been removed.
IOLoop now selects its own port and that is used in tests.

Let me know if I've screwed something up.