God is Love (1 John 4:8) and God loves you. You and I are both children of our Heavenly Father, and so believe it or not, when we put our trust in our Heavenly Father, everything he puts us through, and every commandment He gives us is for our benefit and to strengthen us.
I definitely have personal experience and testimony of this. I have been blessed with a wonderful life, with many amazing opportunities that God has, for some reason, given to me. I sometimes wonder, "Why me? Why have I been so blessed?" It's easy to see why a loving God would bless us with so many wonderful things and opportunities, but often it's hard to imagine why He would give us difficulties and challenges. Why do you think He would do that? No text-book answers! Answer from the heart from personal experiences. Thanks! :)