Skip to content

Commit

Permalink
Merge branch '5.1' into 5.2
Browse files Browse the repository at this point in the history
* 5.1:
  Fix parameter order
  [DependencyInjection] Fix circular in DI with lazy + byContruct loop
  adjust Client::getProfile() typehint
  adjust KernelBrowser::getProfile() typehint
  fix: resolving pt translation issues
  Update VERSION for 3.4.47
  Update CONTRIBUTORS for 3.4.47
  Update CHANGELOG for 3.4.47
  Add Romanian missing translations
  [DependencyInjection][Translator] Silent deprecation triggered by libxml_disable_entity_loader
  fix lexing strings containing escaped quotation characters
  prevent duplicated error message for file upload limits
  ignore the pattern attribute for textareas
  fix: solving pt-br translation issues
  • Loading branch information
derrabus committed Nov 28, 2020
2 parents c60cf99 + a6d771e commit b13a8f9
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
8 changes: 8 additions & 0 deletions Resources/translations/security.ro.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,14 @@
<source>Account is locked.</source>
<target>Contul este blocat.</target>
</trans-unit>
<trans-unit id="17">
<source>Too many failed login attempts, please try again later.</source>
<target>Prea multe încercări de autentificare eșuate, vă rugăm să încercați mai târziu.</target>
</trans-unit>
<trans-unit id="18">
<source>Invalid or expired login link.</source>
<target>Link de autentificare invalid sau expirat.</target>
</trans-unit>
</body>
</file>
</xliff>
14 changes: 14 additions & 0 deletions Tests/Resources/TranslationFilesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,20 @@ public function testTranslationFileIsValid($filePath)
$this->assertCount(0, $errors, sprintf('"%s" is invalid:%s', $filePath, \PHP_EOL.implode(\PHP_EOL, array_column($errors, 'message'))));
}

/**
* @dataProvider provideTranslationFiles
*/
public function testTranslationFileIsValidWithoutEntityLoader($filePath)
{
$document = new \DOMDocument();
$document->loadXML(file_get_contents($filePath));
libxml_disable_entity_loader(true);

$errors = XliffUtils::validateSchema($document);

$this->assertCount(0, $errors, sprintf('"%s" is invalid:%s', $filePath, \PHP_EOL.implode(\PHP_EOL, array_column($errors, 'message'))));
}

public function provideTranslationFiles()
{
return array_map(
Expand Down

0 comments on commit b13a8f9

Please sign in to comment.