[
https://issues.apache.org/jira/browse/LUCENENET-493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13396022#comment-13396022
]
Christopher Currens commented on LUCENENET-493:
-----------------------------------------------
I understood what you've done, I didn't mean that anything that you've done
wasn't working, but that the original port of the code was based on something
that would never had worked in NUnit. Still, I don't want to close the issue
until we've solved the testing issue, so that anyone who runs the tests, not
just those with a different system culture, can verify that it is culture
neutral.
> Make lucene.net culture insensitive (like the java version)
> -----------------------------------------------------------
>
> Key: LUCENENET-493
> URL: https://issues.apache.org/jira/browse/LUCENENET-493
> Project: Lucene.Net
> Issue Type: Bug
> Components: Lucene.Net Core, Lucene.Net Test
> Affects Versions: Lucene.Net 3.0.3
> Reporter: Luc Vanlerberghe
> Labels: patch
> Fix For: Lucene.Net 3.0.3
>
> Attachments: Lucenenet-493.patch
>
>
> In Java, conversion of the basic types to and from strings is locale
> (culture) independent. For localized input/output one needs to use the
> classes in the java.text package.
> In .Net, conversion of the basic types to and from strings depends on the
> default Culture. Otherwise you have to specify CultureInfo.InvariantCulture
> explicitly.
> Some of the testcases in lucene.net fail if they are not run on a machine
> with culture set to US.
> In the current version of lucene.net there are patches here and there that
> try to correct for some specific cases by using string replacement (like
> System.Double.Parse(s.Replace(".",
> CultureInfo.CurrentCulture.NumberFormat.NumberDecimalSeparator)), but that
> seems really ugly.
> I submit a patch here that removes the old workarounds and replaces them by
> calls to classes in the Lucene.Net.Support namespace that try to handle the
> conversions in a compatible way.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira