You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by "Ludovic HOCHET (JIRA)" <ji...@apache.org> on 2016/02/16 00:12:18 UTC

[jira] [Comment Edited] (LOG4J2-1276) LoggerMessageSupplierTest and LoggerSupplierTest are Locale sensitive

    [ https://issues.apache.org/jira/browse/LOG4J2-1276?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15147875#comment-15147875 ] 

Ludovic HOCHET edited comment on LOG4J2-1276 at 2/15/16 11:11 PM:
------------------------------------------------------------------

With [LOG4J2-1277] in, I would rather use the constructor with the Locale.US rather than relying on Locale.setDefault(..)
patch-log4j2-1276-2.diff does that.


was (Author: lhochet):
With [LOG4J2-1277] in, I would rather use the constructor with the Locale.US rather than relying on Locale.setDefault(..)

> LoggerMessageSupplierTest and LoggerSupplierTest are Locale sensitive
> ---------------------------------------------------------------------
>
>                 Key: LOG4J2-1276
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-1276
>             Project: Log4j 2
>          Issue Type: Test
>          Components: API
>    Affects Versions: 2.6
>         Environment: French Windows 10, Java 8
>            Reporter: Ludovic HOCHET
>            Assignee: Gary Gregory
>            Priority: Minor
>             Fix For: 2.6
>
>         Attachments: patch-log4j2-1276-2.diff, patch-log4j2-1276.diff
>
>
> The following tests in API are failing on a French Windows 10:
>   LoggerMessageSupplierTest.flowTracing_MessageSupplierOfMessageFormatMessage:103 Missing entry data
> Expected: a string containing "int foo=1,234,567,890"
>      but: was "ENTRY[ FLOW ] TRACE entry int foo=1 234 567 890"
>   LoggerMessageSupplierTest.flowTracing_MessageSupplierOfStringFormattedMessage:173 Missing entry data
> Expected: a string containing "int foo=1,234,567,890"
>      but: was "ENTRY[ FLOW ] TRACE entry int foo=1 234 567 890"
>   LoggerSupplierTest.flowTracing_SupplierOfMessageFormatMessage:116 Missing entry data
> Expected: a string containing "(int foo=1,234,567,890)"
>      but: was "ENTRY[ FLOW ] TRACE entry params(int foo=1 234 567 890)"
>   LoggerSupplierTest.flowTracing_SupplierOfStringFormattedMessage:200 Missing entry data
> Expected: a string containing "(int foo=1,234,567,890)"
>      but: was "ENTRY[ FLOW ] TRACE entry params(int foo=1 234 567 890)"
> MessageFormatMessage uses MessageFormat,format(pattern, args), StringFormattedMessage uses String.format(pattern, args) both are using the default Locale to format the numbers.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org