Here it looks as if the medial prefrontal cortex has a significant role accounting for individual differences in pain perception, the emotional dysregulation seen in autistic individuals, and test anxiety. The MPFC has been implicated in theory mind & an ability to perceive the mental states of others. In the figure below, emotional anxiety about pain, pain perception, and MPFC activation all appear to relate to each other in a linear fashion.

From this autism study, control subjects had an easier time calming their MPFC down (more difference emotion vs. neutral).

Finally, here's the look of your brain getting a pop quiz: look how much happier the MPFC looks (deactivated, warm colors) if you get a chance to practice before a challenging task...

.
Trouble with Deactivation in Autism - Figures HTMLmPFC and mental states pdfIndividual differences in pain-related fear and anxiety pdf
From this autism study, control subjects had an easier time calming their MPFC down (more difference emotion vs. neutral).
Finally, here's the look of your brain getting a pop quiz: look how much happier the MPFC looks (deactivated, warm colors) if you get a chance to practice before a challenging task...
Trouble with Deactivation in Autism - Figures HTML
mPFC and mental states pdf
Individual differences in pain-related fear and anxiety pdf