version: encode to json string
version: remove empty test
[r=rogpeppe] version: marshal to JSON string

This will make the API look nicer.

https://codereview.appspot.com/11589043/