Codeception\Module\WPLoader::ensureDbModuleCompat PHP Method

ensureDbModuleCompat() public method

    public function ensureDbModuleCompat()
    {
        $interference_candidates = ['Db', 'WPDb'];
        $allModules = $this->moduleContainer->all();
        foreach ($interference_candidates as $moduleName) {
            if (!$this->moduleContainer->hasModule($moduleName)) {
                continue;
            }
            /** @var \Codeception\Module $module */
            $module = $allModules[$moduleName];
            $cleanup_config = $module->_getConfig('cleanup');
            if (!empty($cleanup_config)) {
                throw new ModuleConflictException(__CLASS__, "{$moduleName}\nThe WP Loader module is being used together with the {$moduleName} module: the {$moduleName} module should have the 'cleanup' parameter set to 'false' not to interfere with the WP Loader module.");
            }
        }
    }