add test unit for dom