Resonances, also known as quasinormal modes (QNMs) in the non-Hermitian case, play a ubiquitous role in all domains of physics ruled by wave phenomena, notably in continuum mechanics, acoustics, electrodynamics, and quantum theory. The non-Hermiticity arises from the system losses, whether they are material (Joule losses in electromagnetism) or linked to the openness of the problem (radiation losses). In this paper, we focus on the latter delicate matter when considering bounded computational domains mandatory when using, e.g., finite elements. We address the important question of whether dispersive perfectly matched layer (PML) and high-order absorbing boundary conditions offer advantages in QNM computation and modal expansion of the optical responses compared with nondispersive PMLs.