Test for write