Hopefully get Android building and fix double url encoding

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.

And I hope it fixed the double URL encoding bug.