optimize is the first test, adding one for rewriteHref