[DOM] Move fix to DOM part of YUI. Unit test added to cover the case