]> source.dussan.org Git - nextcloud-server.git/commitdiff
Skip apc test when apc is not enabled for CLI
authorBart Visscher <bartv@thisnet.nl>
Fri, 12 Oct 2012 17:08:47 +0000 (19:08 +0200)
committerBart Visscher <bartv@thisnet.nl>
Fri, 12 Oct 2012 17:08:47 +0000 (19:08 +0200)
tests/lib/cache/apc.php

index 0e0edcf58f37a2ceceddf84b098aaeef3f157e8e..f68b97bcbd925f9b58b8c5ee0b5891926de5746d 100644 (file)
 
 class Test_Cache_APC extends Test_Cache {
        public function setUp() {
-               if(!function_exists('apc_store')){
+               if(!extension_loaded('apc')){
                        $this->markTestSkipped('The apc extension is not available.');
                        return;
                }
+               if(!ini_get('apc.enable_cli') && OC::$CLI){
+                       $this->markTestSkipped('apc not available in CLI.');
+                       return;
+               }
                $this->instance=new OC_Cache_APC();
        }
 }