ANN ARBOR, MICH. — A self-driving car is driving past Liberty Street’s charming storefronts when a truck runs a red light. The car screeches to a halt, avoiding a collision by inches.

Except that the truck isn’t real. And Liberty Street’s shops and restaurants are just a painted façade. Almost nothing here in Mcity is real, and that’s just the way Carrie Morton likes it.

“0.1 percent of extreme car testing should be done using real vehicles,” says Morton, deputy director of the University of Michigan’s Mcity facility. “The rest should be some sort of simulation. Anything else is too dangerous.”

DIGITAL GHOST TOWN

Mcity is a sort of digital ghost town that replicates almost any environment that today’s motorists — and tomorrow’s autonomous vehicles — might experience. Its 32 acres contain highways, ramps, tunnels, and roads made of concrete, asphalt, brick, and dirt. There are crosswalks, bike lanes, curbs, and fire hydrants, all surrounded by fake buildings and populated by eerily lifelike crash test dummy pedestrians.