Added dom helpers and tests.