In a 5- to 6-quart pan over high heat, combine margarine, onion, and mushrooms. Cover and cook, stirring occasionally, until liquid evaporates and vegetables are lightly browned, 6 to 10 minutes. Sprinkle vegetables with flour and stir 1 to 2 minutes more.
Stirring, add broth and bring to a simmer; cover and simmer 10 minutes, stirring occasionally. Stir in soy milk and add salt and pepper to taste. Ladle soup into bowls.