(CNN) The judge set to sentence Bill Cosby next week on three counts of aggravated indecent assault denied a defense motion Wednesday to remove himself from the case and reverse an order that allowed the trial to take place.
The comedian's lawyers filed a motion last week arguing that Judge Steven O'Neill was biased because of a past political campaign and "nasty" personal conflict with prior district attorney, Bruce Castor.
In 2016, Castor testified there was a binding agreement that Cosby could not be prosecuted, but O'Neill disagreed, ruling the case could go forward.
In Wednesday's ruling, the court found the motion was not filed in a timely fashion, but even still had no merit.
"This Court is confident that it has and can continue to assess this case in an impartial manner, free of personal bias or interest in the outcome," O'Neill wrote in the order. "This Court finds no merit in any of the bases alleged by the Defendant and Court will not recuse itself."