You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Dawid Weiss (JIRA)" <ji...@apache.org> on 2012/05/30 22:40:23 UTC

[jira] [Created] (LUCENE-4094) Randomize file.encoding

Dawid Weiss created LUCENE-4094:
-----------------------------------

             Summary: Randomize file.encoding
                 Key: LUCENE-4094
                 URL: https://issues.apache.org/jira/browse/LUCENE-4094
             Project: Lucene - Java
          Issue Type: Sub-task
          Components: general/test
            Reporter: Dawid Weiss
            Priority: Trivial


Stated in the code:
{code}
    // TODO we can't randomize this yet (it drives ant crazy) but this makes tests reproduce
    // in case machines have different default charsets...
    sb.append(" -Dargs=\"-Dfile.encoding=" + System.getProperty("file.encoding") + "\"");
{code}

But this should work without any problems with junit4 because communication streams are separate and we're decoding output properly (or so I hope). 

Try and see what happens :)

--
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

        

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


[jira] [Assigned] (LUCENE-4094) Randomize file.encoding

Posted by "Dawid Weiss (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENE-4094?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dawid Weiss reassigned LUCENE-4094:
-----------------------------------

    Assignee: Dawid Weiss
    
> Randomize file.encoding
> -----------------------
>
>                 Key: LUCENE-4094
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4094
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Assignee: Dawid Weiss
>            Priority: Trivial
>
> Stated in the code:
> {code}
>     // TODO we can't randomize this yet (it drives ant crazy) but this makes tests reproduce
>     // in case machines have different default charsets...
>     sb.append(" -Dargs=\"-Dfile.encoding=" + System.getProperty("file.encoding") + "\"");
> {code}
> But this should work without any problems with junit4 because communication streams are separate and we're decoding output properly (or so I hope). 
> Try and see what happens :)

--
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

        

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


[jira] [Commented] (LUCENE-4094) Randomize file.encoding

Posted by "Robert Muir (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-4094?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286028#comment-13286028 ] 

Robert Muir commented on LUCENE-4094:
-------------------------------------

This would be really nice. The limitation before, if i remember right, was in ant-junit, because
by changing the default charset of the forked jvm, it would also change the encoding of the output from the test runner:
this caused it to go crazy.

It would be nice if junit4 could somehow separate these two concerns: if this could somehow work, imagine how tests running with
a default charset like UTF-16LE would actually fail when they rely upon the system charset and shouldnt, even if they use all 
ascii in their tests like they usually do.

                
> Randomize file.encoding
> -----------------------
>
>                 Key: LUCENE-4094
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4094
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>
> Stated in the code:
> {code}
>     // TODO we can't randomize this yet (it drives ant crazy) but this makes tests reproduce
>     // in case machines have different default charsets...
>     sb.append(" -Dargs=\"-Dfile.encoding=" + System.getProperty("file.encoding") + "\"");
> {code}
> But this should work without any problems with junit4 because communication streams are separate and we're decoding output properly (or so I hope). 
> Try and see what happens :)

--
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

        

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


[jira] [Commented] (LUCENE-4094) Randomize file.encoding

Posted by "Dawid Weiss (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENE-4094?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13286036#comment-13286036 ] 

Dawid Weiss commented on LUCENE-4094:
-------------------------------------

junit4 is already default encoding independent (it uses its own communication channel). I haven't tested this intensively though so I'll give it a shot locally first and them if everything works well, switch the testing framework to randomize file.encoding.

                
> Randomize file.encoding
> -----------------------
>
>                 Key: LUCENE-4094
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4094
>             Project: Lucene - Java
>          Issue Type: Sub-task
>          Components: general/test
>            Reporter: Dawid Weiss
>            Priority: Trivial
>
> Stated in the code:
> {code}
>     // TODO we can't randomize this yet (it drives ant crazy) but this makes tests reproduce
>     // in case machines have different default charsets...
>     sb.append(" -Dargs=\"-Dfile.encoding=" + System.getProperty("file.encoding") + "\"");
> {code}
> But this should work without any problems with junit4 because communication streams are separate and we're decoding output properly (or so I hope). 
> Try and see what happens :)

--
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

        

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