[backport] Auto coerce bytes to string on own json module.a

Only for tests.