rewrite test