Mia Farrow claimed he molested Dylan. I’ve never heard that Dylan testified to it in any forum, public or judicial.
By the way, did you know that Mia Farrow wrote a character reference to the LA DA for Polanski, when they were prosecuting him for raping that 13 year old girl? She defends Polanski to this day.
Dylan was very young at the time of the hearings. Who knows what really happened. This article gives some details.
http://www.vanityfair.com/magazine/archive/1992/11/farrow199211