(of people)behaving in a particular way or doing a particular activity only when it is pleasant for thema fair-weather friend(= somebody who stops being a friend when you are in trouble)Oxford Collocations DictionaryFair-weather is used with these nouns: friendSeefull entry
See fair-weather in the Oxford Advanced American Dictionary