I was in a previous relationship when I found out. He was okay about it, but nothing to write home about.
Now, for my husband, I told him the very first time we went out. It wasn't easy, but I just told him straight up that I have this problem and if he had any qualms about it, he could leave now. I explained a little about it since he'd never heard of IBS. He said so what, everyone's got problems, and he's been 100% supportive ever since.