Solar powered lights are designed to be quite weatherproof and sturdy, because the way they are installed and used involves them most probably being set up outside the house, probably in a way where there is nothing present to shade or protect them from the elements and exposure. That's just the way it is because of how they are designed to work. The devices need sunlight, and while it is possible for a solar panel to collect energy from inside a window, in some cases, it will usually be able to do a much better job if it is located outside, directly out under the sun. And while it's outside, it will also do a much better job of collecting the sun's rays, and turning the sunlight into a form of energy that the device can use, if there is nothing blocking the solar panel, or located between it and the sun, or possibly casting its shadow on the solar panel. So ideally, it would be better if the solar panel and device is not placed under a shade or cover or awning. So since the device is located outside in such a way that it isn't protected from the elements, the ability of the device to withstand relatively harsh temperatures and conditions is important.

That said, some conditions are worse than others, and when we're talking about hail, then it really will depend on the circumstances. It's much better for the device of course if hail is either mostly non-existent or at least very rare in the area where the device is located. When hail does strike though, it is fairly certain that the device will put up a good fight, although this will also depend on the specific circumstances as well as the device's build quality, but the outcome will also heavily depend on the severity of the hail storm. It will depend on how large exactly are the pieces which are falling from the sky and landing on the property. It will depend on how long the event lasts, and if any precautions were taken by the property owner, such as providing at least partial cover for the devices outside. In the end, really, the point is that solar lights are quite sturdy devices in their own right, but even these may not necessarily always come out unscathed when the elements or nature seem like they're out to do their worst. That said, solar powered lights are still an excellent purchase in many cases.