-
Notifications
You must be signed in to change notification settings - Fork 77
Fix #15. Add tests cases using other languages. #16
Conversation
}); | ||
|
||
|
||
it('en-US', function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this test be called fr-FR instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah this was a copy paste error.
It'd be nice to have some pluralization tests in here as well (such as testing that count:3 matches "few" in some specific languages but "other" in |
@drewfish yeah i can totally see that, but I'm not familiar with any other languages to know what the best course of a test would be. |
i am in the process to give you some plural examples, give me 3mins. |
Of course the CLDR stuff will need to be in to test plurals :) |
here is a basic plural + gender with French. be aware that the list pattern is created by hand. en-US: {TRAVELLERS} went to {CITY}. 1st 2nd 3rd |
for few, many let me get some, I am not 100% sure if the one I have in mind is correct, so give me some mins |
en-US ru-RU for en-US it is clear the expected result, so i will only paste the one for ru-RU 1st test: 2nd test 3rd test 4t test 5t test |
One of the tests for Russian is now failing, though it should pass when CLDR is in place. I'm leaving it as is to verify CLDR is working later on. |
ok so you are not committing the russian one? and which one is failing just to know |
No I would commit it, there would just be a failing test. |
Is this okay to merge in? |
+1 |
We should fix this failing test before we merge. |
can you confirm why is failing? which test is the one failing? |
It's failing because there is no CLDR available yet :) |
ok let be more clear :) which specific test is failing? or all of them are failing? |
Oh, the pluralized |
then why don't you remove the ru-RU and then after we have the cldr you commit the ru-RU ? |
i am actually double checking ru-RU as I have some doubts, so you can remove it for now and then I can double check and when CLDR is there we can test it again. |
based on this: https://github.com/papandreou/node-cldr/blob/master/3rdparty/cldr/common/supplemental/plurals.xml#L188 ru seems to have only "one many other" but i know that it has "few" too, and even the twitter implementation has it: I definitely need to double check. |
Yeah, Russian appears to have "few" as witnessed on this page: |
BTW it appears that Arabic ("ar") and Welsh ("cy") have the full complement of groups ("zero", "one", "two", "few", "many", "other") so those might be good candidates for testing. |
correct, because at the implementation level: it only has: one, many, other. so remove ru test case for now. |
I've filed papandreou/node-cldr#11 on the upstream |
ok, i found that on the latest version of CLDR they merged few -> other: http://cldr.unicode.org/index/downloads/cldr-24 then search for: "few (2-4,…) ➞ other (all fractions): Russian" |
let me update the test case for ru-RU without "few" |
@drewfish here is the latest one (version 24): which has one many other |
@apipkin feel free to remove "few" from ru-RU test case. |
I'm okay with waiting on this until CLDR is merged. I just wasn't sure if this was good to merge in before. I'm quite okay with waiting. |
|
yeahhh |
Fix #15. Add tests cases using other languages using test parameters provided by @lwelti