test for writing