Skip to content

Commit

Permalink
Merge branch '3.0'
Browse files Browse the repository at this point in the history
* 3.0:
  [3.0] [Tests] minor fix following #17787
  [2.8] [Form] minor fix some tests with placeholder in AbstractLayout
  [DependencyInjection] fix tests
  Validate XLIFF translation files
  [DependencyInjection] replace alias in factories
  replace alias in factory services
  • Loading branch information
fabpot committed Feb 26, 2016
2 parents 33672bb + 27e1636 commit e7d6b38
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions Tests/Resources/TranslationFilesTest.php
@@ -0,0 +1,31 @@
<?php

/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/

namespace Symfony\Component\Validator\Tests\Resources;

class TranslationFilesTest extends \PHPUnit_Framework_TestCase
{
/**
* @dataProvider provideTranslationFiles
*/
public function testTranslationFileIsValid($filePath)
{
\PHPUnit_Util_XML::loadfile($filePath, false, false, true);
}

public function provideTranslationFiles()
{
return array_map(
function ($filePath) { return (array) $filePath; },
glob(dirname(dirname(__DIR__)).'/Resources/translations/*.xlf')
);
}
}

0 comments on commit e7d6b38

Please sign in to comment.