Do "good for you" and "I am happy for you" have a negative or positive connotation?

At face value, and taken literally, these are both positive.

Both can also be said sarcastically or with self-pity, and in that sense they could be negative.