Why Does Allah Test Those He Loves Most?

Amy suffers from extreme pain due to a bad knee, and she can’t seem to find a good husband. Why is God making her suffer if He loves her?