A longtime friend of state Sen. Dean Skelos testified at the former majority leader’s corruption trial Thursday that he couldn’t fire the powerful politician’s son for not showing up to the cushy job he’d arranged because he feared he’d “have a problem in Albany.”

Adam Skelos, 33, only landed the $78,000-a-year program director job at medical malpractice company Physicians’ Reciprocal Insurers after his dad asked Anthony Bonomo, his friend and the firm’s CEO, to hook him up.

“I was trying to help Adam out,” Bonomo testified in Manhattan federal court, where both Skeloses are on trial. “I felt it would please the senator naturally and Adam if I could get him a job with [health] benefits.”

Skelos, 67, also “always” made his staff available to hear from the four lobbying groups PRI employed.

But on Thursday, Bonomo found himself testifying against Skelos and his son pursuant to a non-prosecution agreement with the feds.

The father and son are accused of using Dean Skelos’ influence as one of the three most powerful elected officials in the state — alongside the Assembly speaker and governor — to pressure companies into giving Adam jobs for which he either wasn’t qualified or just didn’t do.

Bonomo said problems arose just 10 days after Adam started at PRI in January 2013, when the 33-year-old pitched a fit to his dad about how supervisor Chris Curcio was “picking on him” for not showing up to the office.

‘I did not want to have a problem in Albany… [Dean] is the majority leader. He’s responsible for legislation up there’

- Anthony Bonomo

“[The senator] seemed upset at the fact that Christopher was giving Adam a hard time,” he said. “It seemed Christopher was not picking on Adam but rather, was trying to be his supervisor.”

But the elder Skelos was adamant that Curcio was “lying” — and told Bonomo in a phone call to “work this out.”

“To me, it meant I had to find a way to make this work,” Bonomo said. “I did not want to have a problem in Albany … He [Dean] is the majority leader. He’s responsible for legislation up there.”

Bonomo, 57, also advised his brother Carl, a PRI exec, to “do nothing” about writing up a six-month review for Adam.

“I just felt it was best to do nothing and avoid the chance in Albany that we’d run into problems with any legislation,” he said. “I knew how important Adam was to the senator.”

But a few months later, after Adam argued with Curcio and threatened, “I’ll smash your f—ing head in,” he was transferred to a $3,000-a-month consulting positionthat involved calling doctors about insurance coverage.

“Did PRI sign up any doctors as a result of Adam Skelos’ work?” asked prosecutor Tatiana Martins.

“No,” Bonomo answered.

Bonomo also testified that while he felt sorry for Adam, who has a son with development disabilities, that wasn’t the reason why he employed him.

“It had nothing to do with whether I kept him in the office,” he said.

Earlier Thursday, jurors heard testimony from Elizabeth Garvey, a lawyer for the Senate majority leader who worked under Dean when he held the top post.

Garvey said Dean’s chief of staff Robert Mujica had her arrange a 2014 meeting between state Department of Health officials and AbTech Industries, the environmental firm that paid Adam an upwards of $10,000-a-month for consulting work.