Development

Changeset 7108

You must first sign up to be able to contribute.

Changeset 7108

Show
Ignore:
Timestamp:
01/20/08 08:44:42 (2 years ago)
Author:
Carl.Vondrick
Message:

sfLucene: merging trunk changes to 1.1 branch

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • plugins/sfLucenePlugin/branches/1.1

    • Property svn:externals deleted
  • plugins/sfLucenePlugin/branches/1.1/CHANGELOG

    r6883 r7108  
    2020  * BC: sfLuceneCriteria constructor now requires sfLucene instance 
    2121  * Refactored highlighting system 
     22  * Added ability to lock the Propel behavior. 
    2223 
    2324Version 0.1.1 Beta 
  • plugins/sfLucenePlugin/branches/1.1/LICENSE

    r6247 r7108  
    33-------------------------------------------------------------------------------- 
    44 
    5 Copyright (c) 2007 Carl Vondrick 
     5Copyright (c) 2007 - 2008 Carl Vondrick 
    66 
    77Permission is hereby granted, free of charge, to any person obtaining a copy of 
  • plugins/sfLucenePlugin/branches/1.1/README

    r6890 r7108  
    154154after the class declaration.  So, for a blog, you would open project/lib/model/BlogPost.php and append the above, replacing "!MyModel" with "!BlogPost". 
    155155 
     156If you wish to disable the Propel behavior so that no indexing can occur, you can simply do: 
     157{{{ 
     158sfLucenePropelBehavior::setLock(true); // disables Propel behavior, no indexing 
     159sfLucenePropelBehavior::setLock(false); // enables Propel behavior, does index 
     160}}} 
     161 
     162By default, the behavior is not locked so indexing does occur. 
     163 
    156164== Advanced Model Settings == 
    157165You can configure the model even more.  If the peer does not follow symfony's naming conventions, you can specify a new one with in the project level search.yml: 
  • plugins/sfLucenePlugin/branches/1.1/data/skeleton/module/actions/actions.class.php

    r6395 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Module 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id: actions.class.php 6247 2007-12-01 03:25:13Z Carl.Vondrick $ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/data/skeleton/module/actions/components.class.php

    r6395 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1414 * @package    sfLucenePlugin 
    1515 * @subpackage Module 
    16  * @author     Carl Vondrick <carlv@carlsoft.net> 
     16 * @author     Carl Vondrick <carl@carlsoft.net> 
    1717 * @version SVN: $Id: components.class.php 6247 2007-12-01 03:25:13Z Carl.Vondrick $ 
    1818 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneDirectoryStorage.class.php

    r6680 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneFileStorage.class.php

    r6680 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneLowerCaseFilter.class.php

    r6681 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/behavior/sfLucenePropelBehavior.class.php

    r6733 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Behavior 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
     
    2626   */ 
    2727  protected $deleteQueue = array(); 
     28 
     29  /** 
     30   * If true, then nothing can be added to the queues. 
     31   */ 
     32  static protected $locked = false; 
    2833 
    2934  /** 
     
    3641  public function preSave($node) 
    3742  { 
     43    if (self::$locked) 
     44    { 
     45      return; 
     46    } 
     47 
    3848    if ($node->isModified() || $node->isNew()) 
    3949    { 
     
    7787  public function preDelete($node) 
    7888  { 
     89    if (self::$locked) 
     90    { 
     91      return; 
     92    } 
     93 
    7994    if (!$node->isNew()) 
    8095    { 
     
    126141    foreach ($this->getSearchInstances($node) as $instance) 
    127142    { 
    128       $instance->getIndexer()->getModel($node)->delete(); 
     143      $instance->getIndexerFactory()->getModel($node)->delete(); 
    129144    } 
    130145  } 
     
    137152    foreach ($this->getSearchInstances($node) as $instance) 
    138153    { 
    139       $instance->getIndexer()->getModel($node)->insert(); 
     154      $instance->getIndexerFactory()->getModel($node)->insert(); 
    140155    } 
    141156  } 
     
    192207    return sfLucenePropelInitializer::getInstance(); 
    193208  } 
     209 
     210  /** 
     211   * Locks the Propel behavior, so nothing can be queued. 
     212   * @param bool $to If true, the behavior is locked.  If false, the behavior is unlocked. 
     213   */ 
     214  static public function setLock($to) 
     215  { 
     216    self::$locked = (bool) $to; 
     217  } 
    194218} 
  • plugins/sfLucenePlugin/branches/1.1/lib/behavior/sfLucenePropelInitializer.class.php

    r6733 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Behavior 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/category/sfLuceneCategories.class.php

    r6489 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Category 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
     
    5858 
    5959    $this->load(); 
     60  } 
     61 
     62  public function __destruct() 
     63  { 
     64    $this->save(); 
    6065  } 
    6166 
  • plugins/sfLucenePlugin/branches/1.1/lib/category/sfLuceneCategory.class.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Category 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/config/sfLuceneModuleConfigHandler.class.php

    r6696 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111 * @package    sfLucenePlugin 
    1212 * @subpackage Config 
    13  * @author     Carl Vondrick <carlv@carlsoft.net> 
     13 * @author     Carl Vondrick <carl@carlsoft.net> 
    1414 * @version SVN: $Id$ 
    1515 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/config/sfLuceneProjectConfigHandler.class.php

    r6705 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111 * @package    sfLucenePlugin 
    1212 * @subpackage Config 
    13  * @author     Carl Vondrick <carlv@carlsoft.net> 
     13 * @author     Carl Vondrick <carl@carlsoft.net> 
    1414 * @version SVN: $Id$ 
    1515 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/event/sfLuceneEventConnector.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1414 * @package    sfLucenePlugin 
    1515 * @subpackage Event 
    16  * @author     Carl Vondrick <carlv@carlsoft.net> 
     16 * @author     Carl Vondrick <carl@carlsoft.net> 
    1717 * @version SVN: $Id$ 
    1818 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/event/sfLuceneEventConnectorLogger.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1414 * @package    sfLucenePlugin 
    1515 * @subpackage Event 
    16  * @author     Carl Vondrick <carlv@carlsoft.net> 
     16 * @author     Carl Vondrick <carl@carlsoft.net> 
    1717 * @version SVN: $Id$ 
    1818 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneException.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1010 * @package sfLucenePlugin 
    1111 * @subpackage Exception 
    12  * @author Carl Vondrick <carlv@carlsoft.net> 
     12 * @author Carl Vondrick <carl@carlsoft.net> 
    1313 * @version SVN: $Id$ 
    1414 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneHighlighterException.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1010 * @package sfLucenePlugin 
    1111 * @subpackage Exception 
    12  * @author Carl Vondrick <carlv@carlsoft.net> 
     12 * @author Carl Vondrick <carl@carlsoft.net> 
    1313 * @version SVN: $Id$ 
    1414 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneHighlighterXMLException.class.php

    r6911 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1010 * @package sfLucenePlugin 
    1111 * @subpackage Exception 
    12  * @author Carl Vondrick <carlv@carlsoft.net> 
     12 * @author Carl Vondrick <carl@carlsoft.net> 
    1313 * @version SVN: $Id$ 
    1414 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneIndexerException.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1010 * @package sfLucenePlugin 
    1111 * @subpackage Exception 
    12  * @author Carl Vondrick <carlv@carlsoft.net> 
     12 * @author Carl Vondrick <carl@carlsoft.net> 
    1313 * @version SVN: $Id$ 
    1414 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneResultsException.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1010 * @package sfLucenePlugin 
    1111 * @subpackage Exception 
    12  * @author Carl Vondrick <carlv@carlsoft.net> 
     12 * @author Carl Vondrick <carl@carlsoft.net> 
    1313 * @version SVN: $Id$ 
    1414 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneCacheFilter.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneExecutionFilter.class.php

    r6671 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneRenderingFilter.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/filter/sfLuceneHighlightFilter.class.php

    r6911 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 * @package sfLucenePlugin 
    1717 * @subpackage Filter 
    18  * @author Carl Vondrick <carlv@carlsoft.net> 
     18 * @author Carl Vondrick <carl@carlsoft.net> 
    1919 * @version SVN: $Id$ 
    2020 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneAdvancedForm.class.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717 * @package    sfLucenePlugin 
    1818 * @subpackage Form 
    19  * @author     Carl Vondrick <carlv@carlsoft.net> 
     19 * @author     Carl Vondrick <carl@carlsoft.net> 
    2020 * @version SVN: $Id$ 
    2121 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneAdvancedFormBase.class.php

    r6816 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717 * @package    sfLucenePlugin 
    1818 * @subpackage Form 
    19  * @author     Carl Vondrick <carlv@carlsoft.net> 
     19 * @author     Carl Vondrick <carl@carlsoft.net> 
    2020 * @version SVN: $Id$ 
    2121 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneForm.class.php

    r6816 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1414 * @package    sfLucenePlugin 
    1515 * @subpackage Form 
    16  * @author     Carl Vondrick <carlv@carlsoft.net> 
     16 * @author     Carl Vondrick <carl@carlsoft.net> 
    1717 * @version SVN: $Id$ 
    1818 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneSimpleForm.class.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717 * @package    sfLucenePlugin 
    1818 * @subpackage Form 
    19  * @author     Carl Vondrick <carlv@carlsoft.net> 
     19 * @author     Carl Vondrick <carl@carlsoft.net> 
    2020 * @version SVN: $Id$ 
    2121 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneSimpleFormBase.class.php

    r6816 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717 * @package    sfLucenePlugin 
    1818 * @subpackage Form 
    19  * @author     Carl Vondrick <carlv@carlsoft.net> 
     19 * @author     Carl Vondrick <carl@carlsoft.net> 
    2020 * @version SVN: $Id$ 
    2121 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/helper/sfLuceneHelper.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111 * @package    sfLucenePlugin 
    1212 * @subpackage Helper 
    13  * @author     Carl Vondrick <carlv@carlsoft.net> 
     13 * @author     Carl Vondrick <carl@carlsoft.net> 
    1414 * @version SVN: $Id$ 
    1515 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeyword.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordNamed.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordNamedInsensitive.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordZend.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1414 * @package    sfLucenePlugin 
    1515 * @subpackage Highlighter 
    16  * @author     Carl Vondrick <carlv@carlsoft.net> 
     16 * @author     Carl Vondrick <carl@carlsoft.net> 
    1717 * @version SVN: $Id$ 
    1818 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterToken.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarker.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerDry.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerHarness.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerSprint.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerUppercase.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighter.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1515 * @package    sfLucenePlugin 
    1616 * @subpackage Highlighter 
    17  * @author     Carl Vondrick <carlv@carlsoft.net> 
     17 * @author     Carl Vondrick <carl@carlsoft.net> 
    1818 * @version SVN: $Id$ 
    1919 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterHTML.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterHTMLPart.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterString.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXHTML.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
     
    4242  } 
    4343 
    44   protected function doHighlightNode(DOMNode $node) 
     44  protected function ignoreNode(DOMNode $node) 
    4545  { 
    46     if ($this->ignoreNode($node)) 
     46    if (!parent::ignoreNode($node)) 
    4747    { 
    48       return
     48      return ($node->nodeName == 'script' || $node->nodeName == 'style' || $node->nodeName == 'textarea')
    4949    } 
    5050 
    51     parent::doHighlightNode($node); 
    52   } 
    53  
    54   protected function ignoreNode(DOMNode $node) 
    55   { 
    56     return ($node->nodeName == 'script' || $node->nodeName == 'style' || $node->nodeName == 'textarea'); 
     51    return true; 
    5752  } 
    5853} 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXHTMLPart.class.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
     
    2121  { 
    2222    // convert the data to a full document and we'll remove this part later 
    23     $this->data = '<html><body>' . $this->data . '</body></html>'; 
     23    $this->data = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-200000126/DTD/xhtml1-transitional.dtd"><html><body>' . $this->data . '</body></html>'; 
    2424 
    2525    parent::prepare(); 
  • plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXML.class.php

    r6911 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Highlighter 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
     
    4848    $this->document = new DomDocument($this->version, $this->encoding); 
    4949    $this->document->resolveExternals = true; 
    50     $this->document->substituteEntities = true; 
     50    $this->document->substituteEntities = false; 
    5151 
    5252    if (!$this->document->loadXML($this->data)) 
     
    9292  protected function doHighlightNode(DOMNode $node) 
    9393  { 
    94     $texts = array(); 
    95  
    96     if (!$node->hasChildNodes()) 
     94    if ($this->ignoreNode($node)) 
    9795    { 
    9896      return; 
    9997    } 
     98 
     99    $texts = array(); 
    100100 
    101101    foreach ($node->childNodes as $child) 
     
    118118 
    119119  /** 
     120   * Determines if the node should be ignored.  If this returns true, then 
     121   * it and all children are ignored.  If false, then it is highlighted. 
     122   */ 
     123  protected function ignoreNode(DOMNode $node) 
     124  { 
     125    switch ($node->nodeType) 
     126    { 
     127      case XML_ATTRIBUTE_NODE: 
     128      case XML_ENTITY_REF_NODE: 
     129      case XML_ENTITY_NODE: 
     130      case XML_PI_NODE: 
     131      case XML_COMMENT_NODE: 
     132      case XML_DOCUMENT_TYPE_NODE: 
     133      case XML_DOCUMENT_FRAG_NODE: 
     134      case XML_NOTATION_NODE: 
     135        return true; 
     136    } 
     137 
     138    if (!$node->hasChildNodes()) 
     139    { 
     140      return true; 
     141    } 
     142 
     143    return false; 
     144  } 
     145 
     146  /** 
    120147   * Highlights a text node 
    121148   * 
     
    124151  protected function doHighlightTextNode(DOMNode $node) 
    125152  { 
    126     foreach ($this->tokenize($node->nodeValue) as $token) 
     153    foreach ($this->tokenize($node->textContent) as $token) 
    127154    { 
    128155      $node->splitText($token->getEnd()); 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneActionIndexer.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneActionIndexerHandler.class.php

    r6793 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexer.class.php

    r6816 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    136136  protected function addCategory($category, $c = 1) 
    137137  { 
    138     $this->getSearch()->getCategories()->getCategory($category)->add($c)->getHolder()->save(); 
     138    $this->getSearch()->getCategoriesHarness()->getCategory($category)->add($c); 
    139139  } 
    140140 
     
    146146  protected function removeCategory($category, $c = 1) 
    147147  { 
    148     $this->getSearch()->getCategories()->getCategory($category)->subtract($c)->getHolder()->save(); 
     148    $this->getSearch()->getCategoriesHarness()->getCategory($category)->subtract($c); 
    149149  } 
    150150 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexerFactory.class.php

    r6703 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexerHandler.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneModelIndexer.class.php

    r6816 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneModelIndexerHandler.class.php

    r6489 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLucenePropelIndexer.class.php

    r6816 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLucenePropelIndexerHandler.class.php

    r6810 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneActionResult.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Results 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneModelResult.class.php

    r6771 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Results 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/results/sfLucenePager.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717 * @package    sfLucenePlugin 
    1818 * @subpackage Results 
    19  * @author     Carl Vondrick <carlv@carlsoft.net> 
     19 * @author     Carl Vondrick <carl@carlsoft.net> 
    2020 * @version SVN: $Id$ 
    2121 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneResult.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Results 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneResults.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 * @package    sfLucenePlugin 
    1717 * @subpackage Results 
    18  * @author     Carl Vondrick <carlv@carlsoft.net> 
     18 * @author     Carl Vondrick <carl@carlsoft.net> 
    1919 * @version SVN: $Id$ 
    2020 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/sfLucene.class.php

    r6808 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616* the Zend Search Lucene library. 
    1717* 
    18 * @author Carl Vondrick <carlv@carlsoft.net> 
     18* @author Carl Vondrick <carl@carlsoft.net> 
    1919* @package sfLucenePlugin 
    2020* @version SVN: $Id$ 
     
    2222class sfLucene 
    2323{ 
    24   /** 
    25    * Holds various misc. parameters 
     24  const VERSION = '0.2-DEV'; 
     25 
     26  /** 
     27   * Holds the internal dispatcher for this Lucene instance. 
     28   */ 
     29  protected $dispatcher = null; 
     30 
     31  /** 
     32   * Holds the Lucene instance 
     33   */ 
     34  protected $lucene = null; 
     35 
     36  /** 
     37   * Holds the indexer factory singleton 
     38   */ 
     39  protected $indexerFactory = null; 
     40 
     41  /** 
     42   * Holds the categories singleton 
     43   */ 
     44  protected $categoriesHarness = null; 
     45 
     46  /** 
     47   * Holds parameters for this lucene instance 
    2648   */ 
    2749  protected $parameters = null; 
     
    5072    $this->setParameter('index_location', sfConfig::get('sf_data_dir') . DIRECTORY_SEPARATOR.'index'.DIRECTORY_SEPARATOR . $name . DIRECTORY_SEPARATOR . $culture); 
    5173 
    52     $this->setParameter('event_dispatcher', new sfEventDispatcher)
     74    $this->dispatcher = new sfEventDispatcher
    5375 
    5476    $this->initialize(); 
     
    227249  * Returns the categories for this index. 
    228250  */ 
    229   public function getCategories() 
    230   { 
    231     if (!$this->getParameterHolder()->has('categories')
    232     { 
    233       $this->setParameter('categories', new sfLuceneCategories($this)); 
    234     } 
    235  
    236     return $this->getParameter('categories')
     251  public function getCategoriesHarness() 
     252  { 
     253    if ($this->categoriesHarness == null
     254    { 
     255      $this->categoriesHarness = new sfLuceneCategories($this); 
     256    } 
     257 
     258    return $this->categoriesHarness
    237259  } 
    238260 
     
    245267    $location = $this->getParameter('index_location'); 
    246268 
    247     if (!$this->getParameterHolder()->has('lucene')
     269    if ($this->lucene == null
    248270    { 
    249271      sfLuceneToolkit::loadZend(); 
     
    272294      } 
    273295 
    274       $this->setParameter('lucene', $lucene)
     296      $this->lucene = $lucene
    275297   } 
    276298 
    277     return $this->getParameter('lucene')
     299    return $this->lucene
    278300  } 
    279301 
     
    282304  * @return mixed An instance of the indexer factory. 
    283305  */ 
    284   public function getIndexer() 
    285   { 
    286     if (!$this->getParameterHolder()->has('indexer_factory')
    287     { 
    288       $this->setParameter('indexer_factory', new sfLuceneIndexerFactory($this)); 
    289     } 
    290  
    291     return $this->getParameter('indexer_factory')
     306  public function getIndexerFactory() 
     307  { 
     308    if ($this->indexerFactory == null
     309    { 
     310      $this->indexerFactory = new sfLuceneIndexerFactory($this); 
     311    } 
     312 
     313    return $this->indexerFactory
    292314  } 
    293315 
     
    297319  public function getEventDispatcher() 
    298320  { 
    299     return $this->getParameter('event_dispatcher')
     321    return $this->dispatcher
    300322  } 
    301323 
    302324  /** 
    303325  * Gets the context.  Right now, this exists for forward-compatability. 
    304   * TODO: Remove singleton 
     326  * TODO: Remove singleton (depends on sfConfiguration) 
    305327  */ 
    306328  public function getContext() 
     
    374396    $this->getEventDispatcher()->notify(new sfEvent($this, 'lucene.log', array('Rebuilding index...'))); 
    375397 
    376     $this->getCategories()->clear()->save(); 
     398    $this->getCategoriesHarness()->clear(); 
    377399 
    378400    $original = $this->getParameter('delete_lock', false); 
    379401    $this->setParameter('delete_lock', true); // tells the indexers not to bother deleting 
    380402 
    381     foreach ($this->getIndexer()->getHandlers() as $handler) 
     403    foreach ($this->getIndexerFactory()->getHandlers() as $handler) 
    382404    { 
    383405      $handler->rebuild(); 
     
    588610  public function friendlyFind($query) 
    589611  { 
    590     return new sfLuceneResults( $this->find($query), $this); 
     612    return new sfLuceneResults($this->find($query), $this); 
    591613  } 
    592614 
     
    614636    unset(self::$instances[$this->getParameter('name')][$this->getParameter('culture')]); 
    615637  } 
     638 
     639  /** 
     640   * Force the index to use a Lucene instance.  Do not ever use except for unit 
     641   * testing. 
     642   */ 
     643  public function forceLucene($lucene) 
     644  { 
     645    $this->lucene = $lucene; 
     646  } 
     647 
     648  /** 
     649   * Force the index to use a indexer factory.  Do not ever use except for unit 
     650   * testing. 
     651   */ 
     652  public function forceIndexerFactory($factory) 
     653  { 
     654    $this->indexerFactory = $factory; 
     655  } 
    616656} 
  • plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorage.class.php

    r6440 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Storage 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorageBlackhole.class.php

    r6816 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Storage 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorageFilesystem.class.php

    r6657 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Storage 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneAboutTask.class.php

    r6580 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111* Task that dumps information about sfLucene 
    1212* 
    13 * @author Carl Vondrick <carlv@carlsoft.net> 
     13* @author Carl Vondrick <carl@carlsoft.net> 
    1414* @package sfLucenePlugin 
    1515* @subpackage Tasks 
     
    4646    $app = $arguments['application']; 
    4747 
    48     $version = file_get_contents(dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR .'VERSION'); 
    49  
    50     $this->notifyListRow('Plugin Version', $version); 
     48    $this->notifyListRow('Plugin Version', 'sfLucene ' . sfLucene::VERSION); 
    5149 
    5250    if ($app) 
  • plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneBaseTask.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111* This class represents a base task for all sfLucene tasks. 
    1212* 
    13 * @author Carl Vondrick <carlv@carlsoft.net> 
     13* @author Carl Vondrick <carl@carlsoft.net> 
    1414* @package sfLucenePlugin 
    1515* @subpackage Tasks 
  • plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneCleanupTask.class.php

    r6405 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111* This task rebuilds the entire index. 
    1212* 
    13 * @author Carl Vondrick <carlv@carlsoft.net> 
     13* @author Carl Vondrick <carl@carlsoft.net> 
    1414* @package sfLucenePlugin 
    1515* @subpackage Tasks 
  • plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneInitializeModuleTask.class.php

    r6405 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111* Task that initializes a skeleton module to customize. 
    1212* 
    13 * @author Carl Vondrick <carlv@carlsoft.net> 
     13* @author Carl Vondrick <carl@carlsoft.net> 
    1414* @package sfLucenePlugin 
    1515* @subpackage Tasks 
  • plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneInitializeTask.class.php

    r6405 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111* Task that initializes all the configuration files. 
    1212* 
    13 * @author Carl Vondrick <carlv@carlsoft.net> 
     13* @author Carl Vondrick <carl@carlsoft.net> 
    1414* @package sfLucenePlugin 
    1515* @subpackage Tasks 
  • plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneOptimizeTask.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111* This task optimizes all the indexes. 
    1212* 
    13 * @author Carl Vondrick <carlv@carlsoft.net> 
     13* @author Carl Vondrick <carl@carlsoft.net> 
    1414* @package sfLucenePlugin 
    1515* @subpackage Tasks 
  • plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneRebuildTask.class.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111* This task rebuilds the entire index. 
    1212* 
    13 * @author Carl Vondrick <carlv@carlsoft.net> 
     13* @author Carl Vondrick <carl@carlsoft.net> 
    1414* @package sfLucenePlugin 
    1515* @subpackage Tasks 
  • plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneBrowser.class.php

    r6288 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1212 * @package    sfLucenePlugin 
    1313 * @subpackage Utilities 
    14  * @author     Carl Vondrick <carlv@carlsoft.net> 
     14 * @author     Carl Vondrick <carl@carlsoft.net> 
    1515 * @version SVN: $Id$ 
    1616 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneCriteria.class.php

    r6808 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    2121 * @package    sfLucenePlugin 
    2222 * @subpackage Utilities 
    23  * @author     Carl Vondrick <carlv@carlsoft.net> 
     23 * @author     Carl Vondrick <carl@carlsoft.net> 
    2424 * @version SVN: $Id$ 
    2525 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneToolkit.class.php

    r6655 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Utilities 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatter.class.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Widget 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatterAdvanced.class.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Widget 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatterSimple.class.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Widget 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/actions/actions.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1414 * @package    sfLucenePlugin 
    1515 * @subpackage Module 
    16  * @author     Carl Vondrick <carlv@carlsoft.net> 
     16 * @author     Carl Vondrick <carl@carlsoft.net> 
    1717 * @version SVN: $Id$ 
    1818 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/actions/components.class.php

    r6247 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1414 * @package    sfLucenePlugin 
    1515 * @subpackage Module 
    16  * @author     Carl Vondrick <carlv@carlsoft.net> 
     16 * @author     Carl Vondrick <carl@carlsoft.net> 
    1717 * @version SVN: $Id$ 
    1818 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/lib/BasesfLuceneActions.class.php

    r6808 r7108  
    22/* 
    33 * This file is part of the sfLucenePLugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1313 * @package    sfLucenePlugin 
    1414 * @subpackage Module 
    15  * @author     Carl Vondrick <carlv@carlsoft.net> 
     15 * @author     Carl Vondrick <carl@carlsoft.net> 
    1616 * @version SVN: $Id$ 
    1717 */ 
     
    200200  protected function configureCategories($form) 
    201201  { 
    202     $categories = $this->getLuceneInstance()->getCategories()->getAllCategories(); 
     202    $categories = $this->getLuceneInstance()->getCategoriesHarness()->getAllCategories(); 
    203203 
    204204    if (!sfConfig::get('app_lucene_categories', true) || count($categories) == 0) 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/lib/BasesfLuceneComponents.class.php

    r6577 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1111 * @package    sfLucenePlugin 
    1212 * @subpackage Module 
    13  * @author     Carl Vondrick <carlv@carlsoft.net> 
     13 * @author     Carl Vondrick <carl@carlsoft.net> 
    1414 * @version SVN: $Id$ 
    1515 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_actionResult.php

    r6247 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_categories.php

    r6247 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_controls.php

    r6525 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_modelResult.php

    r6247 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_pagerNavigation.php

    r6577 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_publicControls.php

    r6247 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/advancedControls.php

    r6528 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchControls.php

    r6525 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchNoResults.php

    r6525 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchResults.php

    r6577 r7108  
    33 * @package sfLucenePlugin 
    44 * @subpackage Module 
    5  * @author Carl Vondrick <carlv@carlsoft.net> 
     5 * @author Carl Vondrick <carl@carlsoft.net> 
    66 * @version SVN: $Id$ 
    77 */ 
  • plugins/sfLucenePlugin/branches/1.1/package.xml

    r6656 r7108  
    33  <name>sfLucenePlugin</name> 
    44  <channel>pear.symfony-project.com</channel> 
    5   <summary>sfLucene instantly adds a search engine to your application.</summary> 
    6   <description>sfLucene integrates symfony, your ORM layer, and Zend Search Lucene together to instantly add a powerful but flexible search engine.</description> 
     5  <summary>A symfony plugin</summary> 
     6  <description>A symfony plugin</description> 
    77  <lead> 
    8     <name>Carl Vondrick</name
    9     <user>carl</user
    10     <email>carl@carlsoft.net</email
    11     <active>yes</active
     8    <name/
     9    <user/
     10    <email/
     11    <active/
    1212  </lead> 
    13   <date>2007-12-20</date> 
     13  <date>2008-01-03</date> 
    1414  <version> 
    15     <release>0.2.0</release> 
    16     <api>0.2.0</api> 
     15    <release>0.1.0</release> 
     16    <api>0.1.0</api> 
    1717  </version> 
    1818  <stability> 
    19     <release>devel</release> 
    20     <api>devel</api> 
     19    <release>beta</release> 
     20    <api>beta</api> 
    2121  </stability> 
    2222  <license uri="http://www.symfony-project.com/license">MIT license</license> 
    23  <notes>-</notes> 
     23  <notes>-</notes> 
    2424 
    25  <contents> 
     25  <contents> 
    2626 
    27  <dir name="/"><dir name="config"><file name="config_handlers.yml" role="data"/><file name="config.php" role="data"/></dir><dir name="doc"><dir name="generated"/><file name="build_docs.sh" role="data"/></dir><dir name="lib"><dir name="behavior"><file name="sfLucenePropelBehavior.class.php" role="data"/><file name="sfLucenePropelInitializer.class.php" role="data"/></dir><dir name="results"><file name="sfLuceneResults.class.php" role="data"/><file name="sfLuceneActionResult.class.php" role="data"/><file name="sfLucenePager.class.php" role="data"/><file name="sfLuceneResult.class.php" role="data"/><file name="sfLuceneModelResult.class.php" role="data"/></dir><dir name="addon"><dir name="Zend"><dir name="Search"><dir name="Lucene"><file name="sfLuceneFileStorage.class.php" role="data"/><file name="sfLuceneDirectoryStorage.class.php" role="data"/><file name="sfLuceneLowerCaseFilter.class.php" role="data"/></dir></dir></dir></dir><dir name="config"><file name="sfLuceneModuleConfigHandler.class.php" role="data"/><file name="sfLuceneProjectConfigHandler.class.php" role="data"/></dir><dir name="filter"><dir name="browser"><file name="sfLuceneRenderingFilter.class.php" role="data"/><file name="sfLuceneCacheFilter.class.php" role="data"/><file name="sfLuceneExecutionFilter.class.php" role="data"/></dir><file name="sfLuceneHighlightFilter.class.php" role="data"/></dir><dir name="listener"><file name="sfLuceneDoctrineListener.class.php" role="data"/></dir><dir name="util"><file name="sfLuceneCriteria.class.php" role="data"/><file name="sfLuceneBrowser.class.php" role="data"/><file name="sfLuceneToolkit.class.php" role="data"/><file name="sfLuceneHighlighter.class.php" role="data"/></dir><dir name="vendor"><dir name="Zend"><dir name="Search"><dir name="Lucene"><dir name="Analysis"><dir name="Analyzer"><dir name="Common"><dir name="Text"><file name="CaseInsensitive.php" role="data"/></dir><dir name="TextNum"><file name="CaseInsensitive.php" role="data"/></dir><file name="Text.php" role="data"/><file name="TextNum.php" role="data"/><file name="Utf8.php" role="data"/><file name="Utf8Num.php" role="data"/></dir><file name="Common.php" role="data"/></dir><dir name="TokenFilter"><file name="ShortWords.php" role="data"/><file name="LowerCase.php" role="data"/><file name="StopWords.php" role="data"/></dir><file name="Token.php" role="data"/><file name="Analyzer.php" role="data"/><file name="TokenFilter.php" role="data"/></dir><dir name="Storage"><dir name="File"><file name="Filesystem.php" role="data"/><file name="Memory.php" role="data"/></dir><dir name="Directory"><file name="Filesystem.php" role="data"/></dir><file name="File.php" role="data"/><file name="Directory.php" role="data"/></dir><dir name="Search"><dir name="Query"><file name="Wildcard.php" role="data"/><file name="Range.php" role="data"/><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Insignificant.php" role="data"/><file name="Term.php" role="data"/><file name="Fuzzy.php" role="data"/></dir><dir name="Similarity"><file name="Default.php" role="data"/></dir><dir name="QueryEntry"><file name="Subquery.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Weight"><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><file name="QueryHit.php" role="data"/><file name="QueryParserException.php" role="data"/><file name="QueryParser.php" role="data"/><file name="Query.php" role="data"/><file name="QueryLexer.php" role="data"/><file name="QueryToken.php" role="data"/><file name="Similarity.php" role="data"/><file name="BooleanExpressionRecognizer.php" role="data"/><file name="QueryEntry.php" role="data"/><file name="QueryParserContext.php" role="data"/><file name="Weight.php" role="data"/></dir><dir name="Index"><dir name="SegmentWriter"><file name="DocumentWriter.php" role="data"/><file name="StreamWriter.php" role="data"/></dir><file name="DictionaryLoader.php" role="data"/><file name="Writer.php" role="data"/><file name="SegmentInfo.php" role="data"/><file name="FieldInfo.php" role="data"/><file name="SegmentWriter.php" role="data"/><file name="TermInfo.php" role="data"/><file name="SegmentMerger.php" role="data"/><file name="SegmentInfoPriorityQueue.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Document"><file name="Html.php" role="data"/></dir><file name="Document.php" role="data"/><file name="Exception.php" role="data"/><file name="Interface.php" role="data"/><file name="Proxy.php" role="data"/><file name="FSMAction.php" role="data"/><file name="Field.php" role="data"/><file name="FSM.php" role="data"/><file name="PriorityQueue.php" role="data"/></dir><file name="Lucene.php" role="data"/><file name="TODO.txt" role="data"/><file name="Exception.php" role="data"/></dir><file name="LICENSE.txt" role="data"/><file name="Exception.php" role="data"/></dir></dir><dir name="exception"><file name="sfLuceneResultsException.class.php" role="data"/><file name="sfLuceneHighlighterException.class.php" role="data"/><file name="sfLuceneIndexerException.class.php" role="data"/><file name="sfLuceneException.class.php" role="data"/></dir><dir name="indexer"><file name="sfLucenePropelIndexer.class.php" role="data"/><file name="sfLuceneDoctrineIndexer.class.php" role="data"/><file name="sfLuceneIndexerFactory.class.php" role="data"/><file name="sfLuceneActionIndexerHandler.class.php" role="data"/><file name="sfLuceneActionIndexer.class.php" role="data"/><file name="sfLuceneIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexerHandler.class.php" role="data"/><file name="sfLuceneIndexer.class.php" role="data"/><file name="sfLuceneMediaIndexer.class.php" role="data"/><file name="sfLucenePropelIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexer.class.php" role="data"/></dir><file name="sfLucene.class.php" role="data"/><dir name="task"><file name="sfLuceneBaseTask.class.php" role="data"/><file name="sfLuceneRebuildTask.class.php" role="data"/><file name="sfLuceneInitializeTask.class.php" role="data"/><file name="sfLuceneAboutTask.class.php" role="data"/><file name="sfLuceneOptimizeTask.class.php" role="data"/><file name="sfLuceneInitializeModuleTask.class.php" role="data"/><file name="sfLuceneCleanupTask.class.php" role="data"/></dir><dir name="category"><file name="sfLuceneCategories.class.php" role="data"/><file name="sfLuceneCategory.class.php" role="data"/></dir><dir name="storage"><file name="sfLuceneStorageBlackhole.class.php" role="data"/><file name="sfLuceneStorageFilesystem.class.php" role="data"/><file name="sfLuceneStorage.class.php" role="data"/></dir><dir name="form"><file name="sfLuceneSimpleForm.class.php" role="data"/><file name="sfLuceneSimpleFormBase.class.php" role="data"/><file name="sfLuceneAdvancedFormBase.class.php" role="data"/><file name="sfLuceneAdvancedForm.class.php" role="data"/><file name="sfLuceneForm.class.php" role="data"/></dir><dir name="widget"><file name="sfLuceneWidgetFormatter.class.php" role="data"/><file name="sfLuceneWidgetFormatterSimple.class.php" role="data"/><file name="sfLuceneWidgetFormatterAdvanced.class.php" role="data"/></dir><dir name="helper"><file name="sfLuceneHelper.php" role="data"/></dir></dir><dir name="modules"><dir name="sfLucene"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="config"><file name="view.yml" role="data"/></dir><dir name="lib"><file name="BasesfLuceneComponents.class.php" role="data"/><file name="BasesfLuceneActions.class.php" role="data"/></dir><dir name="templates"><file name="searchControls.php" role="data"/><file name="_actionResult.php" role="data"/><file name="_pagerNavigation.php" role="data"/><file name="_modelResult.php" role="data"/><file name="_publicControls.php" role="data"/><file name="_controls.php" role="data"/><file name="_categories.php" role="data"/><file name="searchNoResults.php" role="data"/><file name="searchResults.php" role="data"/><file name="advancedControls.php" role="data"/></dir></dir></dir><dir name="data"><dir name="skeleton"><dir name="app"><dir name="config"><file name="search.yml" role="data"/></dir></dir><dir name="module"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="templates"/></dir><dir name="project"><dir name="config"><file name="search.yml" role="data"/></dir></dir></dir></dir><dir name="web"><dir name="css"><file name="search.css" role="data"/></dir></dir><file name="LICENSE" role="data"/><file name="VERSION" role="data"/><file name="CHANGELOG" role="data"/><file name="package.xml.tpl" role="data"/><file name="package.xml" role="data"/><file name="README" role="data"/></dir></contents> 
     27  <dir name="/"><dir name="config"><file name="config_handlers.yml" role="data"/></dir><dir name="doc"><dir name="generated"/><file name="build_docs.sh" role="data"/></dir><dir name="lib"><dir name="helper"><file name="sfLuceneHelper.php" role="data"/></dir><dir name="widget"><file name="sfLuceneWidgetFormatterSimple.class.php" role="data"/><file name="sfLuceneWidgetFormatter.class.php" role="data"/><file name="sfLuceneWidgetFormatterAdvanced.class.php" role="data"/></dir><dir name="filter"><dir name="browser"><file name="sfLuceneRenderingFilter.class.php" role="data"/><file name="sfLuceneCacheFilter.class.php" role="data"/><file name="sfLuceneExecutionFilter.class.php" role="data"/></dir><file name="sfLuceneHighlightFilter.class.php" role="data"/></dir><dir name="addon"><dir name="Zend"><file name="sfLuceneFileStorage.class.php" role="data"/><file name="sfLuceneDirectoryStorage.class.php" role="data"/><file name="sfLuceneLowerCaseFilter.class.php" role="data"/></dir></dir><dir name="vendor"><dir name="Zend"><file name="LICENSE.txt" role="data"/><file name="Exception.php" role="data"/><dir name="Search"><dir name="Lucene"><dir name="Analysis"><dir name="Analyzer"><dir name="Common"><dir name="Text"><file name="CaseInsensitive.php" role="data"/></dir><dir name="TextNum"><file name="CaseInsensitive.php" role="data"/></dir><file name="Text.php" role="data"/><file name="TextNum.php" role="data"/><file name="Utf8.php" role="data"/><file name="Utf8Num.php" role="data"/></dir><file name="Common.php" role="data"/></dir><dir name="TokenFilter"><file name="ShortWords.php" role="data"/><file name="LowerCase.php" role="data"/><file name="StopWords.php" role="data"/></dir><file name="Token.php" role="data"/><file name="Analyzer.php" role="data"/><file name="TokenFilter.php" role="data"/></dir><dir name="Storage"><dir name="File"><file name="Filesystem.php" role="data"/><file name="Memory.php" role="data"/></dir><dir name="Directory"><file name="Filesystem.php" role="data"/></dir><file name="File.php" role="data"/><file name="Directory.php" role="data"/></dir><dir name="Search"><dir name="Query"><file name="Wildcard.php" role="data"/><file name="Range.php" role="data"/><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Insignificant.php" role="data"/><file name="Fuzzy.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Similarity"><file name="Default.php" role="data"/></dir><dir name="QueryEntry"><file name="Subquery.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Weight"><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><file name="QueryHit.php" role="data"/><file name="QueryParserException.php" role="data"/><file name="QueryParser.php" role="data"/><file name="Query.php" role="data"/><file name="QueryLexer.php" role="data"/><file name="QueryToken.php" role="data"/><file name="Similarity.php" role="data"/><file name="BooleanExpressionRecognizer.php" role="data"/><file name="QueryEntry.php" role="data"/><file name="QueryParserContext.php" role="data"/><file name="Weight.php" role="data"/></dir><dir name="Index"><dir name="SegmentWriter"><file name="DocumentWriter.php" role="data"/><file name="StreamWriter.php" role="data"/></dir><file name="DictionaryLoader.php" role="data"/><file name="Writer.php" role="data"/><file name="SegmentInfo.php" role="data"/><file name="FieldInfo.php" role="data"/><file name="SegmentWriter.php" role="data"/><file name="TermInfo.php" role="data"/><file name="SegmentMerger.php" role="data"/><file name="SegmentInfoPriorityQueue.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Document"><file name="Html.php" role="data"/></dir><file name="Document.php" role="data"/><file name="Exception.php" role="data"/><file name="Interface.php" role="data"/><file name="Proxy.php" role="data"/><file name="FSMAction.php" role="data"/><file name="Field.php" role="data"/><file name="FSM.php" role="data"/><file name="PriorityQueue.php" role="data"/></dir><file name="Lucene.php" role="data"/><file name="TODO.txt" role="data"/><file name="Exception.php" role="data"/></dir></dir></dir><dir name="indexer"><file name="sfLucenePropelIndexer.class.php" role="data"/><file name="sfLuceneIndexerFactory.class.php" role="data"/><file name="sfLuceneActionIndexerHandler.class.php" role="data"/><file name="sfLuceneActionIndexer.class.php" role="data"/><file name="sfLuceneIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexerHandler.class.php" role="data"/><file name="sfLuceneIndexer.class.php" role="data"/><file name="sfLucenePropelIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexer.class.php" role="data"/></dir><dir name="exception"><file name="sfLuceneResultsException.class.php" role="data"/><file name="sfLuceneHighlighterException.class.php" role="data"/><file name="sfLuceneIndexerException.class.php" role="data"/><file name="sfLuceneException.class.php" role="data"/><file name="sfLuceneHighlighterXMLException.class.php" role="data"/></dir><dir name="behavior"><file name="sfLucenePropelBehavior.class.php" role="data"/><file name="sfLucenePropelInitializer.class.php" role="data"/></dir><dir name="results"><file name="sfLuceneResults.class.php" role="data"/><file name="sfLuceneActionResult.class.php" role="data"/><file name="sfLucenePager.class.php" role="data"/><file name="sfLuceneResult.class.php" role="data"/><file name="sfLuceneModelResult.class.php" role="data"/></dir><dir name="task"><file name="sfLuceneOptimizeTask.class.php" role="data"/><file name="sfLuceneInitializeTask.class.php" role="data"/><file name="sfLuceneRebuildTask.class.php" role="data"/><file name="sfLuceneCleanupTask.class.php" role="data"/><file name="sfLuceneInitializeModuleTask.class.php" role="data"/><file name="sfLuceneAboutTask.class.php" role="data"/><file name="sfLuceneBaseTask.class.php" role="data"/></dir><dir name="form"><file name="sfLuceneForm.class.php" role="data"/><file name="sfLuceneAdvancedFormBase.class.php" role="data"/><file name="sfLuceneSimpleFormBase.class.php" role="data"/><file name="sfLuceneAdvancedForm.class.php" role="data"/><file name="sfLuceneSimpleForm.class.php" role="data"/></dir><dir name="storage"><file name="sfLuceneStorage.class.php" role="data"/><file name="sfLuceneStorageBlackhole.class.php" role="data"/><file name="sfLuceneStorageFilesystem.class.php" role="data"/></dir><dir name="config"><file name="sfLuceneModuleConfigHandler.class.php" role="data"/><file name="sfLuceneProjectConfigHandler.class.php" role="data"/></dir><dir name="util"><file name="sfLuceneCriteria.class.php" role="data"/><file name="sfLuceneBrowser.class.php" role="data"/><file name="sfLuceneToolkit.class.php" role="data"/></dir><dir name="category"><file name="sfLuceneCategories.class.php" role="data"/><file name="sfLuceneCategory.class.php" role="data"/></dir><file name="sfLucene.class.php" role="data"/><dir name="event"><file name="sfLuceneEventConnector.class.php" role="data"/><file name="sfLuceneEventConnectorLogger.class.php" role="data"/></dir><dir name="highlighter"><dir name="marker"><file name="sfLuceneHighlighterMarker.class.php" role="data"/><file name="sfLuceneHighlighterMarkerSprint.class.php" role="data"/><file name="sfLuceneHighlighterMarkerHarness.class.php" role="data"/><file name="sfLuceneHighlighterMarkerUppercase.class.php" role="data"/><file name="sfLuceneHighlighterMarkerDry.class.php" role="data"/></dir><file name="sfLuceneHighlighterXHTMLPart.class.php" role="data"/><file name="sfLuceneHighlighterHTML.class.php" role="data"/><dir name="keyword"><file name="sfLuceneHighlighterKeyword.class.php" role="data"/><file name="sfLuceneHighlighterKeywordZend.class.php" role="data"/><file name="sfLuceneHighlighterKeywordNamed.class.php" role="data"/><file name="sfLuceneHighlighterKeywordNamedInsensitive.class.php" role="data"/><file name="sfLuceneHighlighterToken.class.php" role="data"/></dir><file name="sfLuceneHighlighterString.class.php" role="data"/><file name="sfLuceneHighlighterHTMLPart.class.php" role="data"/><file name="sfLuceneHighlighterXHTML.class.php" role="data"/><file name="sfLuceneHighlighter.class.php" role="data"/><file name="sfLuceneHighlighterXML.class.php" role="data"/></dir></dir><dir name="modules"><dir name="sfLucene"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="config"><file name="view.yml" role="data"/></dir><dir name="lib"><file name="BasesfLuceneComponents.class.php" role="data"/><file name="BasesfLuceneActions.class.php" role="data"/></dir><dir name="templates"><file name="advancedControls.php" role="data"/><file name="searchControls.php" role="data"/><file name="_actionResult.php" role="data"/><file name="_pagerNavigation.php" role="data"/><file name="_modelResult.php" role="data"/><file name="_publicControls.php" role="data"/><file name="_controls.php" role="data"/><file name="_categories.php" role="data"/><file name="searchNoResults.php" role="data"/><file name="searchResults.php" role="data"/></dir></dir></dir><dir name="data"><dir name="skeleton"><dir name="app"><dir name="config"><file name="search.yml" role="data"/></dir></dir><dir name="module"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="templates"/></dir><dir name="project"><dir name="config"><file name="search.yml" role="data"/></dir></dir></dir></dir><dir name="web"><dir name="css"><file name="search.css" role="data"/></dir></dir><file name="LICENSE" role="data"/><file name="VERSION" role="data"/><file name="CHANGELOG" role="data"/><file name="package.xml.tpl" role="data"/><file name="package.xml" role="data"/><file name="README" role="data"/><file name="XMLCatalog.tar.gz" role="data"/></dir></contents> 
    2828 
    29  <dependencies> 
    30    <required> 
    31      <php> 
    32        <min>5.2.0</min> 
    33      </php> 
    34      <pearinstaller> 
    35        <min>1.4.1</min> 
    36      </pearinstaller> 
    37      <package> 
    38        <name>sfLucenePlugin</name> 
    39        <channel>pear.symfony-project.com</channel> 
    40        <min>0.0.1</min> 
    41        <max>1.1.0</max> 
    42        <exclude>1.1.0</exclude> 
    43      </package> 
    44    </required> 
    45  </dependencies> 
     29  <dependencies> 
     30    <required> 
     31      <php> 
     32        <min>5.1.0</min> 
     33      </php> 
     34      <pearinstaller> 
     35        <min>1.4.1</min> 
     36      </pearinstaller> 
     37      <package> 
     38        <name>sfLucenePlugin</name> 
     39        <channel>pear.symfony-project.com</channel> 
     40        <min>0.0.1</min> 
     41        <max>1.1.0</max> 
     42        <exclude>1.1.0</exclude> 
     43      </package> 
     44    </required> 
     45  </dependencies> 
    4646 
    47  <phprelease> 
    48  </phprelease> 
     47  <phprelease> 
     48  </phprelease> 
    4949 
    50  <changelog> 
    51  </changelog> 
     50  <changelog> 
     51  </changelog> 
    5252</package> 
  • plugins/sfLucenePlugin/branches/1.1/test

    • Property svn:externals set to
      limeade http://svn.symfony-project.com/plugins/cvLimeadePlugin/trunk/lib

  • plugins/sfLucenePlugin/branches/1.1/test/bin/AllFakeModels.php

    r6392 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/test/bootstrap/unit.php

    r6686 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1515  */ 
    1616 
    17 $app = isset($app) ? $app : 'frontend'; 
    18  
    19 define('SF_ROOT_DIR', dirname(__FILE__) . '/../../../..'); 
    20 define('SF_APP', $app); 
    21 define('SF_ENVIRONMENT', 'dev'); 
    22 define('SF_DEBUG', true); 
    23  
    24 require_once SF_ROOT_DIR.DIRECTORY_SEPARATOR.'apps'.DIRECTORY_SEPARATOR.SF_APP.DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'config.php'; 
    25  
    26 sfContext::getInstance(); 
    27  
    2817error_reporting(E_ALL); 
    2918 
    30 include(SF_ROOT_DIR.DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'config.php'); 
    31 require_once($sf_symfony_lib_dir.'/vendor/lime/lime.php'); 
     19define('SF_ROOT_DIR', realpath(dirname(__FILE__) . '/../../../..')); 
    3220 
    33 define('SANDBOX_DIR', dirname(dirname(__FILE__)) . '/sandbox')
    34 define('DATA_DIR', dirname(dirname(__FILE__)) . '/data')
     21require_once SF_ROOT_DIR . '/config/config.php'
     22require_once $sf_symfony_lib_dir . '/vendor/lime/lime.php'
    3523 
    36 function clear_sandbox() 
    37 
    38   // clear sandbox 
    39   sfToolkit::clearDirectory(SANDBOX_DIR); 
    40 
     24require_once dirname(__FILE__) . '/../limeade/limeade_loader.php'; 
     25require_once dirname(__FILE__) . '/../bin/limeade_lucene.php'; 
    4126 
    42 function configure_i18n($status = true, $culture = 'en_US') 
    43 
    44   if ($status) 
    45   { 
    46     sfConfig::add(array( 
    47       'sf_i18n_default_culture' => 'en_US', 
    48       'sf_i18n_source' => 'XLIFF', 
    49       'sf_i18n_debug' => false, 
    50       'sf_i18n_untranslated_prefix' => '[T]', 
    51       'sf_i18n_untranslated_suffix' => '[/T]', 
    52     )); 
     27limeade_loader::all(); 
    5328 
    54     sfConfig::set('sf_i18n', true); 
    55     sfContext::getInstance()->set('i18n', new sfI18N(sfContext::getInstance()->getEventDispatcher())); 
    56   } 
    57   else 
    58   { 
    59     sfConfig::set('sf_i18n', false); 
    60     sfContext::getInstance()->set('i18n', null); 
    61   } 
    62 } 
    6329 
    64 function remove_from_sfconfig($what) 
    65 { 
    66   $all = sfConfig::getAll(); 
    67   unset($all[$what]); 
    68   sfConfig::clear(); 
    69   sfConfig::add($all); 
    70 } 
    71  
    72 clear_sandbox(); 
    73  
    74 sfConfig::set('sf_config_dir_name', dirname(__FILE__) . '/../data/config'); 
    75 sfConfig::set('sf_data_dir', SANDBOX_DIR . '/data'); 
  • plugins/sfLucenePlugin/branches/1.1/test/coverage.php

    r6671 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneDirectoryStorageTest.php

    r6681 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(7, new lime_output_color()); 
     19$t = new limeade_test(7, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox(); 
    2025 
    2126clearstatcache(); 
    2227 
    23 $d = new sfLuceneDirectoryStorage(SANDBOX_DIR . '/really/long/path/to/something'); 
     28$d = new sfLuceneDirectoryStorage($luceneade->sandbox_dir . '/really/long/path/to/something'); 
    2429 
    2530clearstatcache(); 
    2631 
    27 $t->is(substr(sprintf('%o', fileperms(SANDBOX_DIR . '/really/long/path/to/something')), -4), '0777', '__construct() sets permission to 0777'); 
     32$t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/really/long/path/to/something')), -4), '0777', '__construct() sets permission to 0777'); 
    2833 
    2934$file = $d->createFile('foo'); 
    3035$t->isa_ok($file, 'sfLuceneFileStorage', '->createFile() returns an instance of sfLuceneFileStorage'); 
    31 $t->is(substr(sprintf('%o', fileperms(SANDBOX_DIR . '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777'); 
     36$t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777'); 
    3237 
    3338$file = $d->createFile('foo'); 
    34 $t->is(substr(sprintf('%o', fileperms(SANDBOX_DIR . '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777 if it\'s created again'); 
     39$t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777 if it\'s created again'); 
    3540 
    3641clearstatcache(); 
     
    4045$t->isa_ok($d->getFileObject('foo', false), 'sfLuceneFileStorage', '->getFileObject() returns an instance of sfLuceneFileStorage if told not to share'); 
    4146 
    42 touch(SANDBOX_DIR . '/really/long/path/to/something/bar'); 
     47touch($luceneade->sandbox_dir . '/really/long/path/to/something/bar'); 
    4348 
    4449$t->isa_ok($d->getFileObject('bar'), 'sfLuceneFileStorage', '->getFileObject() returns an instance of sfLuceneFileStorage if the file exists but not handled'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneFileStorageTest.php

    r6681 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(1, new lime_output_color()); 
     19$t = new limeade_test(1, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox(); 
    2025 
    2126clearstatcache(); 
    2227 
    23 touch(SANDBOX_DIR . '/foo'); 
    24 chmod(SANDBOX_DIR . '/foo', 0666); 
     28touch($luceneade->sandbox_dir . '/foo'); 
     29chmod($luceneade->sandbox_dir . '/foo', 0666); 
    2530 
    2631clearstatcache(); 
    2732 
    28 new sfLuceneFileStorage(SANDBOX_DIR . '/foo'); 
     33new sfLuceneFileStorage($luceneade->sandbox_dir . '/foo'); 
    2934 
    3035clearstatcache(); 
    3136 
    32 $t->is(substr(sprintf('%o', fileperms(SANDBOX_DIR . '/foo')), -4), '0777', '__construct() sets permission to 0777'); 
     37$t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/foo')), -4), '0777', '__construct() sets permission to 0777'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneLowerCaseFilterTest.php

    r6681 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(3, new lime_output_color()); 
     19$t = new limeade_test(3, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox(); 
    2025 
    2126$filter = new sfLuceneLowerCaseFilter(false); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/behavior/sfLucenePropelBehaviorTest.php

    r6733 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 
    19  
    20 $t = new lime_test(26, new lime_output_color()); 
     18 
     19$t = new limeade_test(30, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox()->load_models(); 
    2125 
    2226$m1 = new FakeForum; 
     
    5155  { 
    5256    return $this->getSearchInstances($node); 
     57  } 
     58 
     59  public function clear() 
     60  { 
     61    $this->saveQueue = array(); 
     62    $this->deleteQueue = array(); 
    5363  } 
    5464} 
     
    150160$t->is($behavior->_getDeleteQueue(), array(1 => $m2), '->postDelete() removes deleting model from the queue'); 
    151161 
     162$t->diag('testing ::setLock()'); 
     163 
     164$behavior->clear(); 
     165 
     166sfLucenePropelBehavior::setLock(true); 
     167 
     168$m1->setCoolness(4); 
     169 
     170$behavior->preSave($m1); 
     171$t->is(count($behavior->_getSaveQueue()), 0, '::setLock() disables the save queue'); 
     172 
     173$behavior->preDelete($m1); 
     174$t->is(count($behavior->_getDeleteQueue()), 0, '::setLock() disables the delete queue'); 
     175 
     176$behavior->clear(); 
     177 
     178sfLucenePropelBehavior::setLock(false); 
     179 
     180$behavior->preSave($m1); 
     181$t->is(count($behavior->_getSaveQueue()), 1, '::setLock() enables the save queue'); 
     182 
     183$behavior->preDelete($m1); 
     184$t->is(count($behavior->_getDeleteQueue()), 1, '::setLock() enables the delete queue'); 
     185 
     186$behavior->clear(); 
     187 
     188foreach (array($m1, $m2, $m3, $m3) as $m) 
     189{ 
     190  $indexer = new sfLucenePropelIndexer(sfLucene::getInstance('testLucene', 'en'), $m); 
     191  $indexer->delete(); 
     192} 
     193 
    152194$t->diag('testing ->insertIndex()'); 
    153195 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/behavior/sfLucenePropelInitializerTest.php

    r6733 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 
    19  
    20 $t = new lime_test(4, new lime_output_color()); 
     18 
     19$t = new limeade_test(4, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox()->load_models(); 
    2125 
    2226class FooBehavior extends sfPropelBehavior 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/category/sfLuceneCategoriesTest.php

    r6489 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(20, new lime_output_color()); 
     19$t = new limeade_test(20, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox(); 
    2025 
    2126$lucene = sfLucene::getInstance('testLucene', 'en'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/category/sfLuceneCategoryTest.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(15, new lime_output_color()); 
     19$t = new limeade_test(15, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox(); 
    2025 
    2126$lucene = sfLucene::getInstance('testLucene', 'en'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/config/sfLuceneModuleConfigHandlerTest.php

    r6696 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(2, new lime_output_color()); 
     19$t = new limeade_test(2, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox(); 
    2025 
    2126$config = new sfLuceneModuleConfigHandler(); 
    2227 
    23 $response = $config->execute(array(DATA_DIR . '/configTest/module.yml')); 
     28$response = $config->execute(array($luceneade->data_dir . '/configTest/module.yml')); 
    2429 
    2530file_put_contents(lime_test::get_temp_directory() . '/search.yml.php', $response); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/config/sfLuceneProjectConfigHandlerTest.php

    r6706 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(2, new lime_output_color()); 
     19$t = new limeade_test(2, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox()->load_models(); 
    2025 
    2126$config = new sfLuceneProjectConfigHandler(); 
    2227 
    23 $response = $config->execute(array(DATA_DIR . '/configTest/project.yml')); 
     28$response = $config->execute(array($luceneade->data_dir . '/configTest/project.yml')); 
    2429 
    2530file_put_contents(lime_test::get_temp_directory() . '/search.yml.php', $response); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/event/sfLuceneEventConnectorLoggerTest.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(6, new lime_output_color()); 
     19$t = new limeade_test(6, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123class FooListener 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/event/sfLuceneEventConnectorTest.php

    r6792 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(5, new lime_output_color()); 
     19$t = new limeade_test(5, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123class FooListener 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneCacheFilterTest.php

    r6671 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(2, new lime_output_color()); 
     19$t = new limeade_test(2, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123class Foo 
     
    3335 
    3436try { 
     37  $ex = $t->no_exception('->execute() runs without an exception'); 
    3538  $filter->execute($chain); 
    36   $t->pass('->execute() runs without an exception'); 
     39  $ex->no(); 
    3740} catch (Exception $e) { 
    38   $t->fail('->execute() runs without an exception'); 
     41  $ex->caught($e); 
    3942} 
    4043 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneExecutionFilterTest.php

    r6671 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(5, new lime_output_color()); 
     19$t = new limeade_test(5, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123class FooFilter extends sfLuceneExecutionFilter 
     
    3941 
    4042try { 
     43  $ex = $t->no_exception('->execute() runs without exception'); 
    4144  $filter->execute($chain); 
    42   $t->pass('->execute() runs without an exception'); 
     45  $ex->no(); 
    4346} catch (Exception $e) { 
    44   $t->fail('->execute() runs without an exception'); 
     47  $ex->caught($e); 
    4548} 
    4649 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneRenderingFilterTest.php

    r6671 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(3, new lime_output_color()); 
     19$t = new limeade_test(3, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123class Foo 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/filter/sfLuceneHighlightFilterTest.php

    r6891 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(20, new lime_output_color()); 
     19$t = new limeade_test(20, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$chain = new sfFilterChain(); 
     
    157159$t->diag('testing i18n'); 
    158160 
    159 configure_i18n(); 
     161$i18n = $app->i18n()->setup('en_US'); 
    160162 
    161163$response->setContent('<html><body>highlight the keyword</body></html>'); 
     
    164166 
    165167$t->is($response->getContent(), "<?xml version=\"1.0\"?>\n<html><body>highlight the <highlighted>keyword</highlighted></body></html>\n", 'highlighter highlights a single keyword with i18n'); 
     168 
     169$i18n->teardown(); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneAdvancedFormTest.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(10, new lime_output_color()); 
     19$t = new limeade_test(10, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$t->diag('testing constructor'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneFormTest.php

    r6525 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(9, new lime_output_color()); 
     19$t = new limeade_test(9, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123class DummyForm extends sfLuceneForm 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneSimpleFormTest.php

    r6577 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(12, new lime_output_color()); 
     19$t = new limeade_test(12, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$t->diag('testing constructor'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/helper/sfLuceneHelperTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
     18 
     19$t = new limeade_test(16, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    1822 
    1923sfLuceneToolkit::loadZend(); 
     
    4953$foo = new Foo; 
    5054$bar = new Bar; 
    51  
    52 $t = new lime_test(16, new lime_output_color()); 
    5355 
    5456$t->diag('testing partial dependencies'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordNamedInsensitiveTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(15, new lime_output_color()); 
     19$t = new limeade_test(15, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$highlighter = new sfLuceneHighlighterMarkerDry; 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordNamedTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(18, new lime_output_color()); 
     19$t = new limeade_test(18, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$highlighter = new sfLuceneHighlighterMarkerDry; 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordZendTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(1, new lime_output_color()); 
     19$t = new limeade_test(1, limeade_output::get()); 
    2020 
    2121$t->todo('Implementation'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterTokenTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(8, new lime_output_color()); 
     19$t = new limeade_test(8, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$kw = new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerDry, 'foo'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerDryTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(3, new lime_output_color()); 
     19$t = new limeade_test(3, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$marker = new sfLuceneHighlighterMarkerDry; 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerHarnessTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(6, new lime_output_color()); 
     19$t = new limeade_test(6, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$lighters = array( 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerSprintTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(4, new lime_output_color()); 
     19$t = new limeade_test(4, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123try { 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerUppercaseTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(3, new lime_output_color()); 
     19$t = new limeade_test(3, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$marker = new sfLuceneHighlighterMarkerUppercase; 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterHTMLPartTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(1, new lime_output_color()); 
     19$t = new limeade_test(2, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$given = '<p>This is part of a document, dedicated to foobar.</p><p>Look, a foobar</p>'; 
    22  
    2324$expected = '<p>This is part of a document, dedicated to <h>foobar</h>.</p> 
    2425<p>Look, a <h>foobar</h></p> 
     
    3233 
    3334$t->is($highlighter->export(), $expected, '->highlight() highlights a part of the document and returns just that part'); 
     35 
     36$given = '<p>This is p&agrave;rt of a document, dedicated to foobar.</p>'; 
     37$expected = '<p>This is p&agrave;rt of a document, dedicated to <h>foobar</h>.</p> 
     38'; 
     39 
     40$keyword = new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerSprint('<h>%s</h>'), 'foobar'); 
     41 
     42$highlighter = new sfLuceneHighlighterHTMLPart($given); 
     43$highlighter->addKeywords(array($keyword)); 
     44$highlighter->highlight(); 
     45 
     46$t->is($highlighter->export(), $expected, '->highlight() handles entities correctly'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterHTMLTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(2, new lime_output_color()); 
     19$t = new limeade_test(2, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$xml = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterStringTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(8, new lime_output_color()); 
     19$t = new limeade_test(8, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$keywords = array(new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerUppercase, 'foobar'), new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerSprint('"%s"'), 'foobarbaz')); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXHTMLPartTest.php

    r6883 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(2, new lime_output_color()); 
     19$t = new limeade_test(3, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$given = '<p>This is part of a document, dedicated to foobar.</p><p>Look, a foobar</p>'; 
    22  
    2324$expected = '<p>This is part of a document, dedicated to <h>foobar</h>.</p><p>Look, a <h>foobar</h></p>'; 
    2425 
     
    3233 
    3334$given = '<html><body><p>This is part of a document, dedicated to foobar.</p></body></html>'; 
    34  
    3535$expected = '<html><body><p>This is part of a document, dedicated to <h>foobar</h>.</p></body></html>'; 
    3636 
     
    4242 
    4343$t->is($highlighter->export(), $expected, '->highlight() does not fail if it is really a full document'); 
     44 
     45$given = '<p>This is p&agrave;rt of a document, dedicated to foobar.</p>'; 
     46$expected = '<p>This is p&agrave;rt of a document, dedicated to <h>foobar</h>.</p>'; 
     47 
     48$keyword = new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerSprint('<h>%s</h>'), 'foobar'); 
     49 
     50$highlighter = new sfLuceneHighlighterXHTMLPart($given); 
     51$highlighter->addKeywords(array($keyword)); 
     52$highlighter->highlight(); 
     53 
     54$t->is($highlighter->export(), $expected, '->highlight() handles entities correctly'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXHTMLTest.php

    r6891 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(4, new lime_output_color()); 
     19$t = new limeade_test(4, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$xml = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXMLTest.php

    r6891 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(6, new lime_output_color()); 
     19$t = new limeade_test(8, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
    2022 
    2123$xml = '<?xml version="1.0"?> 
     
    104106$t->is($highlighter->export(), $expected, '->highlight() handles multiple keywords'); 
    105107 
     108$xml = '<?xml version="1.0"?> 
     109<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-200000126/DTD/xhtml1-transitional.dtd"> 
     110<root> 
     111  <child>hello &amp; baz&oacute;</child> 
     112  <child>i&nbsp;am foobar</child> 
     113</root> 
     114'; 
     115 
     116$expected = '<?xml version="1.0"?> 
     117<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-200000126/DTD/xhtml1-transitional.dtd"> 
     118<root> 
     119  <child>hello &amp; <s>baz</s>&oacute;</child> 
     120  <child>i&nbsp;am <h>foobar</h></child> 
     121</root> 
     122'; 
     123 
     124$highlighter = new sfLuceneHighlighterXML($xml); 
     125$highlighter->addKeywords(array($keyword, $keyword2)); 
     126$highlighter->highlight(); 
     127 
     128$t->is($highlighter->export(), $expected, '->highlight() handles entities correctly'); 
     129 
     130$xml = '<?xml version="1.0"?> 
     131<root> 
     132  <child>hellÆ bäz</child> 
     133  <child>i am fööbär</child> 
     134</root> 
     135'; 
     136 
     137$expected = '<?xml version="1.0"?> 
     138<root> 
     139  <child>hellÆ <s>bäz</s></child> 
     140  <child>i am <h>fööbär</h></child> 
     141</root> 
     142'; 
     143 
     144$highlighter = new sfLuceneHighlighterXML($xml); 
     145$highlighter->addKeywords(array($keyword, $keyword2)); 
     146$highlighter->highlight(); 
     147 
     148//$t->is($highlighter->export(), $expected, '->highlight() handles UTF8 characters correctly'); 
     149$t->todo('->highlight() handles UTF8 characters correctly (pending elegant solution)'); 
     150 
    106151try { 
    107152  $h = new sfLuceneHighlighterXML('<foo>&ddd;<foo></baz></bar>'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLuceneIndexerFactoryTest.php

    r6703 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 
    1918 
    2019class Foo { } 
     
    2322class sfLuceneActionIndexer { } 
    2423 
    25 $t = new lime_test(14, new lime_output_color()); 
     24$t = new limeade_test(14, limeade_output::get()); 
     25$limeade = new limeade_sf($t); 
     26$app = $limeade->bootstrap(); 
     27 
     28$luceneade = new limeade_lucene($limeade); 
     29$luceneade->configure()->clear_sandbox()->load_models(); 
    2630 
    2731$search = sfLucene::getInstance('testLucene'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLucenePropelIndexerHandlerTest.php

    r6703 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 
     18 
     19$t = new limeade_test(3, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox()->load_models(); 
    1925 
    2026class FooIndexer extends sfLucenePropelIndexerHandler 
     
    2733  } 
    2834} 
    29  
    30 $t = new lime_test(3, new lime_output_color()); 
    3135 
    3236$search = sfLucene::getInstance('testLucene', 'en'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLucenePropelIndexerTest.php

    r6771 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1616 
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 
     18 
     19$t = new limeade_test(64, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox()->load_models(); 
    1925 
    2026class Foo { } 
     
    3036} 
    3137 
    32 $t = new lime_test(64, new lime_output_color()); 
    33  
    3438$lucene = sfLucene::getInstance('testLucene', 'en'); 
    3539$model = new FakeForum; 
     
    283287$t->is($doc->sfl_categories_cache, serialize(explode(' ', $doc->sfl_category)), '->insert() configures categories cache correctly'); 
    284288 
    285 $t->is($lucene->getCategories()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count'); 
    286  
    287 configure_i18n(true, 'en'); 
     289$t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count'); 
     290 
     291$app->i18n()->setup('en'); 
    288292 
    289293$indexer->delete(); 
     
    295299$t->is($doc->sfl_categories_cache, serialize(explode(' ', $doc->sfl_category)), '->insert() configures categories cache correctly with i18n on'); 
    296300 
    297 $t->is($lucene->getCategories()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count with i18n on'); 
    298  
    299 configure_i18n(false); 
     301$t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count with i18n on'); 
     302 
     303$app->i18n()->teardown(); 
    300304 
    301305$h->set('categories', 'Forum'); 
     
    309313$t->is($doc->sfl_categories_cache, serialize(explode(' ', $doc->sfl_category)), '->insert() configures categories cache correctly if just a string'); 
    310314 
    311 $t->is($lucene->getCategories()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count if just a string'); 
     315$t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count if just a string'); 
    312316 
    313317$h->set('categories', array('Forum', '%title%')); 
     
    323327$t->is($doc->sfl_categories_cache, serialize(array('Forum','foobar')), '->insert() configures categories cache correctly with a callback'); 
    324328 
    325 $t->is($lucene->getCategories()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category'); 
    326 $t->is($lucene->getCategories()->getCategory('foobar')->getCount(), 1, '->insert() updated category database count for second category'); 
     329$t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category'); 
     330$t->is($lucene->getCategoriesHarness()->getCategory('foobar')->getCount(), 1, '->insert() updated category database count for second category'); 
    327331 
    328332$indexer->delete(); 
     
    356360$t->is($doc->sfl_categories_cache, serialize(array('Forum','Strings!')), '->insert() configures categories cache correctly with a object-returning callback'); 
    357361 
    358 $t->is($lucene->getCategories()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category with object-returning callback'); 
    359 $t->is($lucene->getCategories()->getCategory('Strings!')->getCount(), 1, '->insert() updated category database count for second category with object-returning callback'); 
     362$t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category with object-returning callback'); 
     363$t->is($lucene->getCategoriesHarness()->getCategory('Strings!')->getCount(), 1, '->insert() updated category database count for second category with object-returning callback'); 
    360364 
    361365$h->remove('categories'); 
     
    388392$t->is($lucene->numDocs(), 0, '->delete() deletes all matching documents in the index'); 
    389393 
    390 $lucene->getCategories()->getCategory('Cat1')->add(5); 
     394$lucene->getCategoriesHarness()->getCategory('Cat1')->add(5); 
    391395 
    392396$h->set('categories', array('Cat1')); 
    393397$indexer->insert(); 
    394398$lucene->commit(); 
    395 $count = $lucene->getCategories()->getCategory('Cat1')->getCount(); 
    396 $indexer->delete(); 
    397  
    398 $t->is($lucene->getCategories()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates the category database count'); 
    399  
    400 $indexer->insert(); 
    401 $count = $lucene->getCategories()->getCategory('Cat1')->getCount(); 
     399$count = $lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(); 
     400$indexer->delete(); 
     401 
     402$t->is($lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates the category database count'); 
     403 
     404$indexer->insert(); 
     405$count = $lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(); 
    402406$h->set('categories', array('Cat2')); 
    403407$indexer->delete(); 
    404408 
    405 $t->is($lucene->getCategories()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates category count that it was indexed with if categories have changed'); 
    406 $t->is($lucene->getCategories()->getCategory('Cat2')->getCount(), 0, '->delete() does not update new category count if categories have changed'); 
     409$t->is($lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates category count that it was indexed with if categories have changed'); 
     410$t->is($lucene->getCategoriesHarness()->getCategory('Cat2')->getCount(), 0, '->delete() does not update new category count if categories have changed'); 
    407411 
    408412$t->diag('testing ->save()'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneActionResultTest.php

    r6685 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(1, new lime_output_color()); 
     19$t = new limeade_test(1, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clear_sandbox(); 
    2025 
    2126$lucene = sfLucene::getInstance('testLucene'); 
  • plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneModelResultTest.php

    r6685 r7108  
    22/* 
    33 * This file is part of the sfLucenePlugin package 
    4  * (c) 2007 Carl Vondrick <carlv@carlsoft.net> 
     4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 
    55 * 
    66 * For the full copyright and license information, please view the LICENSE 
     
    1717require dirname(__FILE__) . '/../../bootstrap/unit.php'; 
    1818 
    19 $t = new lime_test(12, new lime_output_color()); 
     19$t = new limeade_test(12, limeade_output::get()); 
     20$limeade = new limeade_sf($t); 
     21$app = $limeade->bootstrap(); 
     22 
     23$luceneade = new limeade_lucene($limeade); 
     24$luceneade->configure()->clea