public function supports($resource, $type = null) { return 'xlf' === pathinfo($resource, PATHINFO_EXTENSION); }
/** * Tests the supports() method. */ public function testSupports() { $loader = new XliffFileLoader($this->getRootDir() . '/app'); $this->assertTrue($loader->supports($this->getRootDir() . '/vendor/contao/test-bundle/Resources/contao/languages/en/default.xlf')); $this->assertFalse($loader->supports($this->getRootDir() . '/vendor/contao/test-bundle/Resources/contao/languages/en/tl_test.php')); }