Author: dr
Date: Thu Feb 21 16:29:01 2008
New Revision: 7424

Log:
- Skip tests when solr isn't running.

Modified:
    trunk/Search/tests/session_test.php

Modified: trunk/Search/tests/session_test.php
==============================================================================
--- trunk/Search/tests/session_test.php [iso-8859-1] (original)
+++ trunk/Search/tests/session_test.php [iso-8859-1] Thu Feb 21 16:29:01 2008
@@ -25,7 +25,14 @@
 
     public function setUp()
     {
-        $this->backend = new ezcSearchSolrHandler();
+        try
+        {
+            $this->backend = new ezcSearchSolrHandler;
+        }
+        catch ( ezcSearchCanNotConnectException $e )
+        {
+            self::markTestSkipped( 'Solr is not running.' );
+        }
         $this->testFilesDir = dirname( __FILE__ ) . '/testfiles/';
         $this->backend->sendRawPostCommand( 'update', array( 'wt' => 'json' ),
                 '<delete><query>timestamp:[* TO *]</query></delete>' );


-- 
svn-components mailing list
svn-components@lists.ez.no
http://lists.ez.no/mailman/listinfo/svn-components

Reply via email to