reWrite test script