"Are crack sites designed so that people using them will get a virus thus teaching them a lesson on using them?"
Taking the whole sentence above literally, the answer is generally no.
If they give you a virus or some other nasty, it is because they think they can get something out of it (money ultimately). This could be from your machine, or by using your machine to infect others.
They don't do things to "teach you a lesson". There was a time that they did it for kicks but those days are now well behind us.
Some crack sites are safe, but it's a bit like gambling unless you know which ones, ie. The punter mostly looses.