Created
September 15, 2020 23:49
-
-
Save josher19/c4a0450d1eede980342a9e4010c72845 to your computer and use it in GitHub Desktop.
casual locales pollute default casual namespace ... does not support multiple locales
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const assert = require('assert'); | |
const casual = require('casual'); | |
const loc = casual; | |
const de = casual.de_DE; | |
const arabic = casual.ar_SY; | |
const us = casual.en_US; | |
// address_formats should not be changed by loading a new locale, but they are. | |
assert.deepStrictEqual(us.address_formats, loc.address_formats); | |
assert.notDeepStrictEqual(us.address_formats, de.address_formats); | |
assert.notDeepStrictEqual(us.address_formats, arabic.address_formats); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment