Prosecutors on Friday are expected to ask the governor if DiMasi pressured him or his administration in 2007 to approve a contract for the software company Cognos.

The ex-speaker, Richard McDonough and Richard Vitale have pleaded not guilty to an alleged scheme to use DiMasi's Statehouse clout to steer two software contracts worth a combined value of $17.5 million to Cognos, in exchange for kickbacks.

The administration has not been accused of any wrongdoing.

Patrick will be the first sitting Massachusetts governor to testify in a criminal trial since 1995, when then-Gov. William Weld was called in the trial of a state senator who was later acquitted of influence-peddling charges.

The governor arrived at John Joseph Moakley United States Courthouse just after 9 a.m. Friday in a two-vehicle motorcade. His SUV was ushered into a rear garage, where he entered the courthouse out of view of the media throng gathered at the building's main entrance.

Greg Saulmon, assistant online editor for The Republican, contributed to this report.