lib/escaper: add tests about idempotence