mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2025-03-25 12:20:32 -04:00
I changed the semantics of the i18n fallback to not hit 'text' for other properties, so updated a test.
This commit is contained in:
parent
795bd8f63b
commit
4f0805ce1e
2 changed files with 7 additions and 5 deletions
|
@ -28,6 +28,8 @@ getAllLadderScores = (next) ->
|
|||
for level in levels
|
||||
for team in ['humans', 'ogres']
|
||||
'I ... am not doing this.'
|
||||
# Query to get sessions to make histogram
|
||||
# db.level.sessions.find({"submitted":true,"levelID":"brawlwood",team:"ogres"},{"_id":0,"totalScore":1})
|
||||
|
||||
isRequestFromDesignatedCronHandler = (req, res) ->
|
||||
if req.ip isnt config.mail.cronHandlerPublicIP and req.ip isnt config.mail.cronHandlerPrivateIP
|
||||
|
|
|
@ -40,7 +40,7 @@ describe 'utils library', ->
|
|||
expect(util.i18n(this.fixture1, 'text', 'en')).toEqual(this.fixture1.text)
|
||||
expect(util.i18n(this.fixture1, 'blurb', 'en')).toEqual(this.fixture1.blurb)
|
||||
delete this.fixture1.blurb
|
||||
expect(util.i18n(this.fixture1, 'blurb', 'en')).toEqual(this.fixture1.text)
|
||||
expect(util.i18n(this.fixture1, 'blurb', 'en')).toEqual(null)
|
||||
|
||||
it 'i18n can fall forward if a general language is not found', ->
|
||||
expect(util.i18n(this.fixture1, 'text', 'pt')).toEqual(this.fixture1.i18n['pt-BR'].text)
|
||||
|
|
Loading…
Add table
Reference in a new issue