Before the Bertrams and Crawfords know each other very well, Mary goes on a rant in front of everyone about church—“the obligation of attendance, the formality, the restraint, the length of time,” and more. This is an example of dramatic irony because readers know—but Mary does not—that Edmund (her potential love interest listening in on this conversation) is planning to become a clergyman and takes church very seriously. When Julia reveals to the group that Edmund is soon to be ordained, Mary is “aghast” and Fanny pities her, highlighting the irony of the moment:
“My dear Edmund, if you were but in orders now, you might perform the ceremony directly. How unlucky that you are not ordained.”
[…]
Miss Crawford’s countenance, as Julia spoke, might have amused a disinterested observer. She looked almost aghast under the new idea she was receiving. Fanny pitied her. “How distressed she will be at what she said just now,” passed across her mind.
Fanny’s reaction to Mary’s faux pas is quite sympathetic, underlining her caring personality and manners. In contrast, this moment highlights—and foreshadows—Mary’s lack of manners (and lack of religiosity and morality), which will ultimately be the reason that Edmund ends their courtship.