public function getSource($name)
{
$source = $this->loader->getSource($name);
if ($adapter = $this->getSourceAdapter($name)) {
$source = $this->getTwital()->compile($adapter, $source);
}
return $source;
}
public function testNonTwitalFile() { $twital = $this->getMock('Goetas\\Twital\\Twital'); $twitalLoader = new TwitalLoader(new StringLoader(), $twital, false); $twitalLoader->addSourceAdapter('/.*\\.xml$/', new XMLAdapter()); $twital->expects($this->never())->method('compile'); $twitalLoader->getSource('aaa.txt'); }