The ruling class of Jews were constantly trying to trick Jesus into saying something where they could point the finger at Him and say He blasphemed. Especially during this, His last week. They would then have the excuse to kill Him that they longed for.
The Saducees didn't believe that people would enter heaven, no matter how good they were--well, except for Abraham and Moses, maybe. Or Elijah or Elishah. But not the common man. So to trick Jesus, they posed a question.
A Levirate marriage, so called because it is described in the book of Leviticus, was God's remedy for a childless marriage where the husband died. When a man died childless, his wife was then to marry her husband's brother. The first son born to that marriage would be considered the first husband's son and would inherit that husband's land and goods.
The Saducees asked Jesus who would be the woman's husband in heaven if she married one brother after another until she had been widowed six times and had married seven husbands.
I can just see the disgusted expression on Jesus's face. "You are making a mistake in your thinking," He told them. "People there are like the angels. There are no marriages in heaven, nor are there any wedding ceremonies." (That's a pretty rough rendition of Matthew 22:29-30.)
What I really love is what He said next: "But regarding the resurrection of the dead, have you not read what was spoken to you by God: 'I AM THE GOD OF ABRAHAM, AND THE GOD OF ISAAC, AND THE GOD OF JACOB '? He is not the God of the dead but of the living."
Jesus was so good at poking them with their own daggers. I love it--and yet--that's why they made plans to kill him.