public function MemcacheCacheTest::setUp

File

drupal/core/vendor/doctrine/common/tests/Doctrine/Tests/Common/Cache/MemcacheCacheTest.php, line 11

Class

MemcacheCacheTest

Namespace

Doctrine\Tests\Common\Cache

Code

public function setUp() {
  if (extension_loaded('memcache')) {
    $this->_memcache = new \Memcache();
    $ok = @$this->_memcache
      ->connect('localhost', 11211);
    if (!$ok) {
      $this
        ->markTestSkipped('The ' . __CLASS__ . ' requires the use of memcache');
    }
  }
  else {
    $this
      ->markTestSkipped('The ' . __CLASS__ . ' requires the use of memcache');
  }
}