Backport transport_test from tip

Right now, it doesn't pass.  I surmise this is from bugs that have
since been fixed.

Just as well: this was to prepare for backpatching fixes.

Signed-off-by: Daniel Farina <daniel@fdr.io>