harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexey Varlamov" <alexey.v.varla...@gmail.com>
Subject Re: [drlvm] Is Cygwin required for kernel.test?
Date Mon, 09 Apr 2007 04:42:21 GMT
2007/4/8, Mikhail Fursov <mike.fursov@gmail.com>:
> IMO it's really bad test
> and it worth to be rewritten. Why does it have "C:\\CygWin\bin" file
> check with an equal code in if/else blocks?
>
> Instead of sh.exe we can put simple "cmd /C echo Hello World" for Windows

+1
A new JIRA issue seems to be the best way go further.


>
> On 4/8/07, Nathan Beyer <ndbeyer@apache.org> wrote:
> >
> > Does the java.lang.RuntimeTest2 kernel.test in DRLVM require Cygwin to
> > work in a Windows OS? I'm recieving the following failure from the
> > test_exec_Str_F2T1S2Z test method.
> >
> > check002: sh.exe seems to have not been found by default! Please, set
> > the path to sh.exe via java.library.path property.
> >
> > I looked at the code and I don't see how this bit of code could ever
> > succeed in a Windows environment without Cygwin.
> >
> >                 File f = new java.io.File("C:\\CygWin\\bin");
> >                 Process p;
> >                 if (f.exists()) {
> >                     p = Runtime.getRuntime().exec(new String[] {
> >                             cmnd, "/C", "sh", "-c",
> >                             "echo $#; echo $0; echo $1; echo $2; echo $3;
> > " +
> >                             "echo $4; echo $5; echo $6; echo $7",
> >                             "Hello", "HELL", "\"Hello\" \"world\"",
> >                             "World hello", "vas\"a d:?*/\\", "\"World
> > hello\""},
> >                             new String[] {}, f);
> >                     p.waitFor();
> >                 } else {
> >                     p = Runtime.getRuntime().exec(new String[] {
> >                             cmnd, "/C", "sh", "-c",
> >                             "echo $#; echo $0; echo $1; echo $2; echo $3;
> > " +
> >                             "echo $4; echo $5; echo $6; echo $7",
> >                             "Hello", "HELL", "\"Hello\" \"world\"",
> >                             "World hello", "vas\"a d:?*/\\", "\"World
> > hello\""});
> >                     if (p.waitFor() != 0) {
> >                         fail("check002: sh.exe seems to have not been
> > found " +
> >                                 "by default! Please, set the path to
> > sh.exe" +
> >                                 " via java.library.path property.");
> >                     }
> >                 }
> >
> >
> > Was this test previously excluded?
> > -Nathan
> >
>
>
>
> --
> Mikhail Fursov
>

Mime
View raw message