Download the PHP package therichcourt/translations-testing-bundle without Composer
On this page you can find all versions of the php package therichcourt/translations-testing-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download therichcourt/translations-testing-bundle
More information about therichcourt/translations-testing-bundle
Files in therichcourt/translations-testing-bundle
Package translations-testing-bundle
Short Description A simple way to test translations in your Symfony application
License MIT
Informations about the package translations-testing-bundle
Translations Testing Bundle
A simple way to test translations in your Symfony application.
A Symfony bundle, which provides a page in your application to input translation keys and arguments and instantly see the translation results. Useful for testing / debugging ICU based translations with multiple arguments, without having to change the state of your application for each variant, or hunt down the page which uses the translation.
Installation
composer require --dev therichcourt/translations-testing-bundle
Configuration
1. Register the bundle in config/bundles.php
2. Create a configuration for the bundle in config/packages/dev/translations_testing.yaml
3. Set up the routes in config/routes/dev/routes.yaml
That's all the set-up done. You can now go to the page on your site, and start testing translations.
Features
- Translate your keys into all locales
- Test ICU translations, by passing arguments
- Highlights potential issues, e.g. if the translated message matches the key (which could mean you're missing a translation definiton)
N.B. this is not an automated testing solution - it just makes it much easier for you to manually test the results of your translations.
Contributing
Any PRs with fixes or improvements gratefully received.
Setting the project up
Simply fork, clone and then run:
Connect to the container, then in there, run:
Testing
Run composer test
to run all tests and lints.