An error during a Y2K computer test caused a Los Angeles water treatment facility to spill about 4 million gallons of raw sewage into a city park Wednesday night, raising fears about environmental and other problems that could be in store as January 1, 2000 approaches. Maintenance workers had cleaned up most of the mess by yesterday morning, and health officials say the spill posed little danger to the public. In other recent Y2K tests, computers crashed for seven hours at a nuclear power plant in Pennsylvania, and large quantities of chemicals were mistakenly dumped in water in Perth, Australia.