The relay now runs properly in Android!

This fixes the things I broke in Android and also gets all the relay tests
into a form that Android and Java can deal with. I also put in logic to
keep the tests in Android and copy them over to Java. But I have only done
this for the relay test. I haven't done it for our other two test files.