def METHOD_NAME(self):
    # Test importing a top-level module.
    with mock_modules('top_level') as mock:
        with import_state(meta_path=[mock]):
            module = importlib.import_module('top_level')
            self.assertEqual(module.__name__, 'top_level')