What happens when you hit a bicycle helmet with a sledgehammer - video and images
First, I hit the Scott square on the front-top:
I mostly let the sledgehammer fall, and didn't really put much swing into. Seeing that it couldn't stand up to face of the hammer, I hit it with the side of the hammer, again mostly letting the hammer fall rather than really swinging it:
Next, I hit the Bell Aquila with the side of the hammer:
The Bell really did a remarkable job standing up to the hammer. The Styrofoam was completely cracked apart the first strike, but the shell managed to hold the pieces together through several beatings. The Scott was a much older helmet, and its shell had already, for the most, part broken apart from normal wear and UV damage (it started out white, not yellow).
Obvious conclusions: If I'm going to get hit in the head with a sledgehammer, I'll choose a bike helmet even with cracked foam over nothing at all.