I think it was very much in my culture to accept something out of politeness too. My Grandma often said "If someone gives you something, say thankyou" but then I was in a situation with my health , Pre diabetic and other problems where I wanted my friend to support me in not eating sweet things around me. When it comes to your actual health I think anyone who cares for you will understand and realise you need a life change. Anyone who supports you will support your life change and not eat tempting stuff in front of you.
This "friend" did not support me. She deliberately carried on bringing cake and I ended up eating it, then hating myself because I'd ended up not looking after my body and I'd not even enjoyed the nasty cake. She was diabetic but she didn't care and continued to eat loads of sugary foods and then get really ill. That's why I realise now, she didn't respect her body, so she wasn't going to respect mine either. After she moved house it was easier without her. I am now not pre diabetic because I changed my life with my diet and in future I'd avoid anyone who doesn't respect my choice to live as healthy as possible.
I respect her choice to smoke and binge on sugary things, but if she was the one asking me not to tempt her, I genuinely wouldn't.