It is perfectly okay to wash mushrooms before cooking. The key here is, to have the mushrooms whole when washing, that you use cold water, and that you give them a quick shower (using a colander), and not a bath! Many old-school culinary experts are against washing and advise instead, that one cleans the mushrooms with a damp cloth or pastry brush. The thinking behind this is that the mushroom flesh acts like a sponge and tends to absorb water, thereby making them soggy. However, recent kitchen experiments have shown that washing mushrooms does not make them absorb as much water as previously thought.