# How to test localization

**URL:** <https://forums.creativeclouddeveloper.com/t/how-to-test-localization/1329>\
**Category:** UXP Plugin API\
**Tags:** javascript\
**Created:** [October 16, 2019, 6:36pm UTC](https://forums.creativeclouddeveloper.com/t/how-to-test-localization/1329 "2019-10-16T18:36:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Velara](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.creativeclouddeveloper.com/velara/32/1278_2.png) [@Velara](https://forums.creativeclouddeveloper.com/u/Velara)\
**Post date:** [October 16, 2019, 6:36pm UTC](https://forums.creativeclouddeveloper.com/t/how-to-test-localization/1329/1 "2019-10-16T18:36:07Z")

</div>

From the [submission guidelines](https://adobexdplatform.com/plugin-docs/distribution/submission-checklist.html):

> - The plugin must provide localized strings for all languages indicated as supported by the developer and successfully display them _ **when the system is set to each supported locale** _.
> - The plugin UI must not break due to localized strings for supported locales.

How are you testing locales?

---

<div class="post-metadata">

**Author:** ![pklaschka](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.creativeclouddeveloper.com/pklaschka/32/3162_2.png) [@pklaschka](https://forums.creativeclouddeveloper.com/u/pklaschka)\
**Post date:** [October 16, 2019, 6:46pm UTC](https://forums.creativeclouddeveloper.com/t/how-to-test-localization/1329/2 "2019-10-16T18:46:04Z")

</div>

Are you on Windows or macOS? On Windows, it uses the “Display Language” from the Windows Settings, which is (relatively) quick to change. I don’t know about macOS, but usually, I “just” hard-code the language code I want to test into the plugin (one after the other) and test it (or, ideally, I have plugin settings allowing to override “automatic language”)…

---

<div class="post-metadata">

**Author:** ![Velara](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.creativeclouddeveloper.com/velara/32/1278_2.png) [@Velara](https://forums.creativeclouddeveloper.com/u/Velara)\
**Post date:** [October 16, 2019, 6:51pm UTC](https://forums.creativeclouddeveloper.com/t/how-to-test-localization/1329/3 "2019-10-16T18:51:05Z")

</div>

On Mac there’s this window in the System Preferences

 ![image](https://us1.discourse-cdn.com/flex015/uploads/xdplugins/original/1X/e502122d73ed9693bbced3d1e1c66d64ed3771e4.png)

When I switched to another region (locale?) one of Apples apps crashed. 🤔

I guess I can hard code it for testing.

---

<div class="post-metadata">

**Author:** ![pklaschka](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.creativeclouddeveloper.com/pklaschka/32/3162_2.png) [@pklaschka](https://forums.creativeclouddeveloper.com/u/pklaschka)\
**Post date:** [October 16, 2019, 6:58pm UTC](https://forums.creativeclouddeveloper.com/t/how-to-test-localization/1329/4 "2019-10-16T18:58:09Z")

</div>

🤔😆

The truth is that as I use my [`xd-localization-helper`](https://github.com/pklaschka/xd-localization-helper) for all my plugins (now), it’s quite easy as I’ve added an `overrideLanguage` config option to the library specifically for this reason (and maybe for options dialogs allowing users to override the plugin language, [reference](https://github.com/pklaschka/xd-localization-helper/wiki/Reference#localizationhelperloadtranslationfolderlocation-config--promiseboolean)). I can recommend using some sort of library (may that be your own or something like mine) to anyone implementing i18n in plugins and include something like this, it makes things like this a lot easier
