def METHOD_NAME(self):
    """Attempts to import modules of the installed package."""
    # Make sure we are importing the installed modules,
    # not the ones in the source directory
    python = inspect.getmodule(self).python
    for module in self.import_modules:
        with spack.install_test.test_part(
            self,
            "test_imports_{0}".format(module),
            purpose="checking import of {0}".format(module),
            work_dir="spack-test",
        ):
            python("-c", "import {0}".format(module))