mirror of
https://github.com/discourse/discourse.git
synced 2025-02-02 08:06:31 +08:00
038de393ed
Why this change? We have been bitten by bugs where tests are not catching missing interpolate argument in our client side code because the JavaScript tests are also using `I18n.translate` to assert that the right message is shown. Before this change, `I18n.interpolate` will just replace the missing interpolation argument in the final translation with some placeholder. As a result, we ended up comparing a broken translation with another broken translation in the test environment. Why does this change do? This change introduces the `I18n.testing` property which when set to `true` will cause `I18n.translate` to throw an error when an interpolate argument is missing. With this commit, we also set `I18n.testing = true` when running qunit acceptance test. |
||
---|---|---|
.. | ||
admin | ||
bootstrap-json | ||
confirm-new-email | ||
deprecation-silencer | ||
dialog-holder | ||
discourse | ||
discourse-common | ||
discourse-hbr | ||
discourse-plugins | ||
discourse-widget-hbs | ||
docs | ||
ember-addons | ||
ember-cli-progress-ci | ||
ember-production-deprecations | ||
locales | ||
patches | ||
pretty-text | ||
select-kit | ||
truth-helpers | ||
wizard | ||
.licensee.json | ||
.npmrc | ||
handlebars-shim.js | ||
js-processor.js | ||
package.json | ||
polyfills.js | ||
service-worker.js.erb | ||
yarn.lock |