Fix bug in test_jsons