Was a concurrency issue int he Write method that retained the
slice p that was passed in, making concurrency issues much more likely
with unbuffered channels.
Wrote ChannelReadWriter that simulates a connection inmemory.
This is used by the agentserver test for testing the initialization. The
first test is already working.