More JSON-sending fixes
Rewriting some failing tests