On Wed, 9 Dec 2020 15:19:58 GMT, Ivan Šipka <isi...@openjdk.org> wrote:

>> Refactor `test/jdk/java/lang/annotation/loaderLeak/LoaderLeak.sh` as java 
>> test.
>
> Ivan Šipka has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   8166026: Refactor java/lang shell tests to java

Changes requested by iignatyev (Reviewer).

test/jdk/java/lang/annotation/LoaderLeakTest.java line 79:

> 77:                                 
> .directory(Paths.get(Utils.TEST_CLASSES).toFile()
> 78:                         )
> 79:                 ).shouldHaveExitValue(0);

indentation here looks wierd

test/jdk/java/lang/annotation/LoaderLeakTest.java line 54:

> 52:         List<String> classes = List.of("A.class", "B.class", "C.class");
> 53:         for (String fileName : classes) {
> 54:             Files.move(

I don't think it's a good idea to move files created and managed by `jtreg`. 
I'd recommend you copying them here and, in `runJavaProcess...` constructing 
`ProcessBuilder` youself:

var args = new ArrayList<String>(command.length + 1);
args.add(JDKToolFinder.getJDKTool("java"));
Collections.addAll(args, command);
var pb = new 
ProcessBuilder(args).directory(Paths.get(Utils.TEST_CLASSES).toFile());

-------------

PR: https://git.openjdk.java.net/jdk/pull/1577

Reply via email to