Updated some tests around JSON API