⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dbcontainer.php

📁 太烦了
💻 PHP
字号:
<?php

include_once('TestAuthContainer.php');
include_once("Auth/Container/DB.php");


class DBContainer extends TestAuthContainer {

    function DBContainer($name){
        $this->TestAuthContainer($name);
    }
    
    function &getContainer() {
        static $container;
        #print "In DBContainer::getContainer {$this->skip_tests}\n";
        if(!isset($container)){
            include('./auth_container_db_options.php');
            $container = new Auth_Container_DB($options);
            // Catch if DB connection cannot be made
            $res = $container->_prepare();
        }
        
        if(!DB::isConnection($container->db)){
            #print "In DBContainer::getContainer container->db is error \n";
            $this->skip_tests = true;
            $this->skip_tests_message = "SKIP TEST:DB is not a connection object, check dsn !!!";
        }
        return($container);
    }
    
    function &getExtraOptions() {
        include('./auth_container_db_options.php');
        return($extra_options);
    }
}




?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -