Egg safety. When to eat and when to not eat
If the shell is undamaged, and the eggs are not past their expiration/best by date, they are safe to eat. Official source: your government's food safety agency, unless you live in a place with really really lax food regulation. But your profile says Australia - I'm sure things are fine there. If there are problems with salmonella outbreaks, it's not anything that you can detect. A salmonella-contaminated egg will look exactly like an uncontaminated one - that's why governments generally recommend you cook the egg, which will kill the salmonella and make it safe. If you're eating raw/undercooked eggs, you'll have to decide whether the risk where you are is low enough.

In practice, they're actually safe for a while after the best by date, just not as fresh, and if the shell is cracked without damaging the membrane or they were very recently cracked, they're also safe. But no damage and before the date is the most absolute guarantee you can get.

The two tests you mention will help you get some idea how fresh the eggs are. Neither has anything to do with good vs. rotten. As eggs get less fresh, they dry out a bit, forming a larger air pocket. So they'll slosh more, and start to float.

But it doesn't mean they're rotten. An actually rotten egg would be completely obvious by smell - they're sulfurous, a lot like the smell that's added to natural gas. If you're getting eggs that float in water on the day you buy them, with really obvious sloshing, yes, it means they're not fresh, so they're certainly not good as fresh eggs from a farm. So if that's the case, your supermarket isn't selling you good quality eggs. It doesn't mean they're unsafe, though.

As for "Why do most eggs have crap and blood on them?" ... "most" is a huge exaggeration, the places I've seen - they get washed. And as rumtscho pointed out in the comments, the eggs are coming out of a chicken, so some ugly stuff is natural. You never actually said what your eggs look like, but if you live in a place where they're not cleaned (even before selling in a supermarket??), then it still doesn't mean they're unsafe, just that you should probably clean them before cracking them.

And dark spots? Some eggs are naturally speckled - that'd be fine. If it's something else, I guess it would be helpful for you to provide a picture.