The D.C. school system has fired or suspended 32 school bus drivers and bus attendants who failed urinalysis tests to detect drugs, a school system spokesman said yesterday.

D.C. school officials, citing what they called an alarming increase in school bus accidents and misbehavior by bus personnel, ordered the drug testing for the first time this year.

A union spokeswoman who represents 28 part-time workers who were fired charged yesterday that the tests were given to punish the part-time employes for their successful efforts to become unionized earlier this year. Four full-time employes have been suspended as a result of the urine tests.

Schools officials, however, insisted the tests were given to ensure the safety of the special education and handicapped students who ride the buses. Officials reported there were 57 accidents during the 1982 school year and 82 in 1983.

"We have a responsibility to protect kids who use our buses," said school system spokesman Maurice Sykes. "The drug tests helped us screen out people who could possibly cause injury to public school children."

The drug tests were given as part of an annual physical examination that the approximately 200 part-time and 100 full-time transportation workers took in July to qualify for re-licensing, a school system official said.

The urine samples, analyzed by National Health Laboratories, Inc., in Vienna, Va., revealed that there were traces of marijuana, cocaine, PCP or heroin in the urine of those employes who were fired or suspended, the official said, adding that marijuana was the substance most frequently detected. The employes were fired in August, several weeks before schools reopened.

Teachers and other employes were not ordered to take the tests because there has been "no reason to suspect them," said George Margolies, legal counsel for the D.C. schools. He said that in the past 10 years, "just one other employe" was fired or suspended for drug use.

School officials said drug testing may now become a standard requirement for school bus employes, as it is for D.C. police officers and bus drivers who work for the Washington Metropolitan Area Transit Authority.

According to Margolies, the full-time school employes who failed the drug tests were suspended for 30 days without pay instead of being fired because "we wanted to give them the opportunity to re-test and come clean."

The part-time workers, who recently became unionized but have not negotiated a labor contract with the school system, were terminated because "they are intermittent workers and we just chose not to use them anymore," Margolies said. "We had no legal obligation to suspend them. There is a chance that some of them could be used in the future."

Part-time workers earn about $10,000 a year, and full-time drivers and attendants earn about $20,000.

Ruby Huntley, president of the American Federation of State, County and Municipal Employees (AFSCME) Local 2093, which was elected recently to represent the part-time bus drivers and attendants, said that some of the fired employes "were on medication. That was not considered by the officials. They were not allowed to see the results of their tests. They only know what their supervisors told them.

"It's obviously harrassment. Several employes took tests a second time on their own and were cleared, but management has refused to give them back their jobs," Huntley said.

Schools Superintendent Floretta D. McKenzie said the union activity of the workers had nothing to do with the decision to test the drivers and attendants.

In a memo to the D.C. Board of Education last month, she reported that there was an increase in bus accidents in recent years and stated that "several incidents on our buses indicated that the drivers and attendants were possibly under the influence of alcohol or controlled substances."

According to one official, the "incidents" included fighting and arguments among employes.

One part-time bus attendant who was fired said the tests were inaccurate.

"I'm not guilty of anything. I was given a urinalysis and two weeks later I was fired for having marijuana in my urine," said the attendant, who asked not to be identified. "I went to the same clinic and asked for a second test. That test came back negative. I'm suffering an injustice because of a mistake made in a laboratory."