Changeset 1649

Show
Ignore:
Timestamp:
06/23/08 23:40:18 (4 months ago)
Author:
mikey
Message:

remove possibility to configure name of rss-feeds.ini file

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/src/main/php/net/stubbles/xml/rss/stubRSSProcessor.php

    r1594 r1649  
    2525{ 
    2626    /** 
    27      * registry key for the feeds config file 
    28      */ 
    29     const KEY_FEEDS_FILE = 'net.stubbles.xml.rss.feeds'; 
    30     /** 
    3127     * list of configured feeds 
    3228     * 
     
    4036    protected function doConstruct() 
    4137    { 
    42         $this->feeds = $this->loadFeeds(stubConfig::getConfigPath() . DIRECTORY_SEPARATOR . stubRegistry::getConfig(self::KEY_FEEDS_FILE, 'rss-feeds.ini')); 
     38        $this->feeds = $this->loadFeeds(stubConfig::getConfigPath() . DIRECTORY_SEPARATOR . 'rss-feeds.ini'); 
    4339    } 
    4440 
  • trunk/src/test/php/net/stubbles/xml/rss/stubRSSProcessorTestCase.php

    r1595 r1649  
    108108                     ->method('loadFeeds') 
    109109                     ->with($this->equalTo(stubConfig::getConfigPath() . DIRECTORY_SEPARATOR . 'rss-feeds.ini')); 
    110         $rssProcessor->callDoConstruct(); 
    111     } 
    112  
    113     /** 
    114      * construction with configured config file should use configured config file 
    115      * 
    116      * @test 
    117      */ 
    118     public function constructionWithSpecialConfigFile() 
    119     { 
    120         stubRegistry::setConfig(stubRSSProcessor::KEY_FEEDS_FILE, 'rss-test.ini'); 
    121         $rssProcessor = $this->getMock('TeststubRSSProcessor', 
    122                                        array('loadFeeds'), 
    123                                        array($this->mockRequest, 
    124                                              $this->mockSession, 
    125                                              $this->mockResponse 
    126                                        ) 
    127                         ); 
    128         $rssProcessor->expects($this->once()) 
    129                      ->method('loadFeeds') 
    130                      ->with($this->equalTo(stubConfig::getConfigPath() . DIRECTORY_SEPARATOR . 'rss-test.ini')); 
    131110        $rssProcessor->callDoConstruct(); 
    132111    }