added testcase for reading and writing