I think the sunglasses that are worth $50 are very cheap. But some of they also have very good quality. They can protect my eyes too. So you can't say that cheap sunglasses can't protect your eyes. But as to those sunglasses that will only charge for less than $10, I don't know whether I can accept that kind of sunglasses or not because I often doubt their quality so I haven't bought that kind of sunglasses.
Cheap sunglasses can also protect our eyes if the sunglasses can block at least 98-99% UV rays and can filter the harsh glare that reflected from the smooth surfaces of water or a road. But I suggest you to buy the sunglasses that can block 100% UV rays because this kind of sunglasses is good sunglasses. They can better protect your eyes.
There are many cheap sunglasses stores online. Cheap doesn't mean the sunglasses are of poor quality. The cost of a pair of sunglasses is very low. But eyeglasses manufacturers and eyeglasses companies can make a great profit from sunglasses. however, with the development of society, all the things are become more available and cheap except some luxuries. So it is possible to buy a pair of sunglasses of good quality while with low price.