Based on my readings about Thomas More, both historical and fictional (Bolt's play, for example), I think he truly believed that he had to follow his conscience and the teachings of the Roman Catholic Church. I don't think he had any kind of self-confidence in being able to escape execution. He knew that if he went against Henry VIII, he would die, plain and simple. I'm sure there must have been some hope that their friendship would save his life, but I don't think he really would have "bet the farm" on that. He knew what Henry was like, and that Henry was going to have his way, regardless of More's feelings on the subject, or the teachings of the church.