James McWilliams, the second of D.C. Mayor Marion Barry's old acquaintances to turn against him in a deal with federal prosecutors, said yesterday he financed a drug deal, saw the "white substance," smelled the smoke and heard the mayor tell Charles Lewis, "This is good stuff."

But McWilliams never saw the mayor smoke it. In detailed and irreverent testimony, the city official in part backed up Lewis's account of drug use at the downtown Ramada Inn in December 1988.

All the white-haired, gray-bearded McWilliams really wanted that night was a chance to ask the mayor for a new city job, he said. A $73,284-a-year official at the D.C. Department of Public Works, McWilliams, 59, testified that he tried repeatedly to buttonhole Barry for a conversation about a position commensurate with "my training and experience."

Unable to secure Barry's attention, McWilliams testified, he followed the mayor to the smoky bathroom, where Barry sat slumped on the toilet, fully clothed, near a sherbet glass with rumpled-looking tin on top of it. Lewis, a convicted cocaine dealer, has said he and Barry used the foil-topped glass as a crack pipe.

"I kept making my pitch about the job," McWilliams said, "and he looked up at me and he said, 'You know, you look a lot like Santa Claus.' "

"I didn't think I was going to sell my case about the job," McWilliams said he concluded.

Two jurors placed their hands over their faces in the general hilarity of the moment in the courtroom. Barry looked down and adjusted a shirt cuff, not a trace of a smile on his countenance.

Later in the afternoon, another old friend of Lewis's provided more comic relief in a detailed, if sometimes meandering, account of the weekend Lewis used his home to hide out after the so-called Ramada Inn episode of Dec. 22, 1988.

John W. Olsen, a senior management analyst for the Office of Personnel Management who has known Lewis since a federal training program in the Virgin Islands brought them together in 1969, told the jury that Lewis called him on Dec. 23, 1988, after years of silence.

"The phone rang at 11 o'clock in the morning," said Olsen, a burly, bearded man who answered every question in a slow, deliberate cadence. "I answered the phone, as I have always answered the phone, 'This is John Olsen,' so there is no doubt who they are talking to, and a voice on the other end of the line said to me, 'I staying with you for the weekend, mon.' "

Olsen said he had no idea Lewis was a target of media inquiries until the next morning. He said he was cooking breakfast when his son, who was sitting at the kitchen table reading the morning newspaper, said, "Hey, Dad, Mr. Lewis has made the front page!"

The government presented Olsen's testimony mainly to back up details of Lewis's testimony about the weekend after the Ramada Inn incident. In that incident, police officers responding to a complaint about drug activity in Lewis's room were stopped from going to his room after the hotel manager learned Barry was there.

Olsen described a weekend of frantic telephone calls for Lewis at Olsen's home nearly around the clock for four days, with his own wife increasingly irate at this "unwanted visitor," and Lewis himself inexplicably sucking on lemons and drinking cup after cup of hot tea with lemon juice.

Earlier in the week, Lewis testified Barry had told him he could rid his system of evidence of drug use before going to talk to police if he drank large amounts of water and lemon juice.

Olsen's tendency to ramble in response to prosecutors' questions prompted several objections from Barry co-counsel Robert W. Mance. But it appeared by the end of the afternoon to have amused even the judge.

"Ladies and gentlemen, we will conclude for the day and resume at 10 o'clock tomorrow morning," Jackson said. Assistant U.S. Attorney Judith Retchin pointed out that the next day was Saturday.

"Oh, I'm sorry," Jackson said. "I'm having too much fun."

Neither McWilliams nor Olsen directly corroborated the substantive parts of Lewis's testimony, but both offered circumstantial testimony that dovetailed with key parts of Lewis's testimony.

Assistant U.S. Attorney Richard W. Roberts, who questioned McWilliams, tried to use him both to bolster Lewis and to portray Lewis as a fun-loving ne'er-do-well who is, in McWilliams's words, "50 going on 12," and who "turned out to be a dollar short and a day late for 20 years."

McWilliams himself, by contrast, was presented through Roberts's questions as a man of substance: married 26 years, a lawyer with an honorable discharge from the Army and the holder of impressive jobs.

Testifying for most of the day, McWilliams spoke about the mayor as "someone I respect." He had been "a loyal soldier for 15 months," he said, in an attempt to protect Barry, but now "wanted to make a clean breast of what I had done."

McWilliams pleaded guilty last January to one misdemeanor count of aiding and abetting Lewis's possession of cocaine. He was placed on one year's probation and ordered to pay a fine of $1,000.

R. Kenneth Mundy, the mayor's lead attorney, used his opening statement Tuesday to describe both Lewis and McWilliams as "notorious drug dealers" dredged from the "lower recesses of humanity" to implicate Barry. In cross-examination yesterday, co-counsel Mance tried to amplify on that contention with a series of questions aimed at McWilliams's acknowledged involvement in drugs.

During cross-examination, Mance sought repeatedly to elicit from him an admission that he was "distributing" drugs to Yvette Parron, a D.C. government employee whom McWilliams described as "like a daughter."

But McWilliams rephrased each of Mance's questions in terms he liked better.

"And as a part of your agreement for testifying in this case, they agreed not to charge you with those felony charges of distribution, isn't that right?" Mance asked.

"Part of the agreement was that if I testified truthfully, they would not prosecute me for other activities such as receiving small amounts of cocaine and giving it to a friend of mine," McWilliams replied, referring to Parron.

McWilliams's lawyer, Daniel A. Masur, yesterday criticized Mundy's statement that McWilliams is a "notorious drug dealer." Masur said McWilliams has never used drugs, and has never profited from drug sales, but acknowledged he made a "tragic error in judgment" in passing drugs from Lewis to Parron. "He accepts full responsibility for his conduct, deeply regrets that it ever occurred," Masur said of McWilliams.

Yesterday also featured testimony from Fred Gaskins, a D.C. police officer on the mayor's security detail. Gaskins testified he took an envelope from Barry to Lewis's room on the evening of Dec. 19, 1988, and gave it to McWilliams.

Lewis has testified that the envelope contained papers and five $20 bills that Barry had given him to buy crack. But Gaskins testified that he never saw the mayor putting money in the envelope, only papers. Roberts immediately asked him whether he saw what the mayor put in the envelope before he put in the papers. Gaskins said no.

Mance asked him whether he would have left the envelope if he'd thought it contained money. "No," Gaskins said.

Mundy told reporters yesterday that he thinks the defense case would probably be short, holding up his thumb and forefinger with a small space between them.

"Every day the press keeps asking how we think we did with witnesses," he said. "We are not keeping a scorecard . . . . Everybody keeps looking for a knockout with witnesses. I remind you that you win fights also on points, by nicking and bruising." If neither the prosecution nor the defense succeeds in eliciting convincing testimony, he added, "the defense wins all ties, because of the presumption of innocence."

Staff writers Matthew Lee, Elsa Walsh and Michael York contributed to this report.