Showdown has admins working all the time to fix glitches. You'd be surprised at how rare significant glitches actually are. Also I'm pretty sure that every interaction between moves, pokemon, abilities and items are almost exact simulations of what happens. When a new game is released masses of smogoners go into researching game these sorts of things, meaning there are hundreds of combined testing hours into showdown per game.