The elements of dramatic irony add to the humor of the story.
Dramatic irony is when the reader knows something that one of the characters does not. There is a great deal of humor in this story that makes an otherwise dark tale more fun. Humor helps to characterize both Montresor and Fortunato. It also keeps the reader engaged to the very end.
The first example of humor is the way that Montresor messes with Fortunato’s head when he is trying to get him to go into the catacombs. The scene is quite absurd. Fortunato is drunk and dressed as a clown, and Montresor is deadly serious but pretending to be friendly.
He accosted me with excessive warmth, for he had been drinking much. The man wore motley. He had on a tight-fitting parti-striped dress, and his head was surmounted by the conical cap and bells. I was so pleased to see him that I thought I should never have done wringing his hand.
When Montresor tricks Fortunato into going into the catacombs by telling him he has an expensive and rare cask of wine and he is planning to show it to someone else, the reader is sure to chuckle. The dramatic irony is that we know that Montresor really needs to get Fortunato into that cellar. He wants to kill him!
Another example of comic relief is the humor regarding the Masons. Montresor is carrying a trowel, and to explain its presence away he makes a joke about being one of the Masons.
"You are not of the masons."
"Yes, yes," I said; "yes, yes."
"You? Impossible! A mason?"
"A mason," I replied.
"A sign," he said, "a sign."
"It is this," I answered, producing from beneath the folds of my roquelaire a trowel.
"You jest," he exclaimed, recoiling a few paces. "But let us proceed to the Amontillado."
Masons are actually a very prestigious secret society, and when Fortunato makes the gesture Montresor pretends he understands, and then produces the trowel. Fortunato actually does belong to the secret society, and so he laughs it off.
By the time we get to the actual bricking up stage, there is a sort of macabre humor in Fortunato’s actions, but we know that Montresor is not kidding. Fortunato takes a while to become suspicious, but by the time he does it is too late.
Throughout the story humor is created through dramatic irony. We the reader know what is going on, while Fortunato has no clue. He thinks that he is just out on a harmless outing with a friend, but Montresor manipulates him carefully until he finally succeeds in killing him.