Example #1
0
 public static function get_instance()
 {
     if (!isset(self::$instance)) {
         self::$instance = new GlobalsCache();
     }
     return self::$instance;
 }
Example #2
0
 /**
  * @covers GlobalsCache::get_instance
  */
 function testGetInstance()
 {
     $a = GlobalsCache::get_instance();
     $this->assertTrue($a === GlobalsCache::get_instance());
 }