fix some bugs, update-dom case for entangled vars tests