When things are pleasent, we thank Hashem for the enjoyable moment. And when things are challenging, we try to trust that things are for the best. From Tehillim 92
Example of the 2nd
I was engaged, but it didn't work out. It was a mutual decision and we cried while speaking. I know that it's better that it happened beforehand BH, rather than later.
Or I might be in an annoying sitution, but I try to see what I can learn from it, like so and so helped me to be more assertive.
I use to want my days to be perfect, but that doesn't happen, except once in a while. There's always some challenge. The thing is to enjoy whatever enjoyable moment we have. And remember that challenges help us to grow.
We can choose to be happy, when we focus on our blessings
And then we increase our love for Hashem