add TextSerializer for tests