Skip to content

Commit 521144c

Browse files
committed
8251998: remove usage of PropertyResolvingWrapper in vmTestbase/jit/t
Backport-of: 6612598
1 parent f69e75f commit 521144c

File tree

3 files changed

+45
-65
lines changed

3 files changed

+45
-65
lines changed

test/hotspot/jtreg/vmTestbase/jit/t/TEST.properties

Lines changed: 0 additions & 2 deletions
This file was deleted.
Lines changed: 22 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2008, 2020, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -36,14 +36,14 @@
3636
*
3737
* @comment make sure foo.class is only in the current directory
3838
* @clean jit.t.t087.foo
39-
* @run driver PropertyResolvingWrapper ExecDriver --cmd
39+
* @run driver ExecDriver --cmd
4040
* ${compile.jdk}/bin/javac
4141
* -d .
4242
* -cp ${test.class.path}
4343
* ${test.src}/t087.java
4444
*
4545
* @comment run the test
46-
* @run driver PropertyResolvingWrapper ExecDriver --java
46+
* @run driver ExecDriver --java
4747
* -cp .${path.separator}${test.class.path}
4848
* -Dtest.src=${test.src}
4949
* jit.t.t087.t087
@@ -52,49 +52,41 @@
5252

5353
package jit.t.t087;
5454

55-
import java.io.File;
56-
import nsk.share.TestFailure;
5755
import nsk.share.GoldChecker;
5856

59-
class foo
60-
{
61-
static void bar()
62-
{
57+
import java.io.File;
58+
59+
class foo {
60+
static void bar() {
6361
t087.goldChecker.println("You shouldn't see this.");
6462
}
6563
}
6664

67-
class t087
68-
{
69-
public static final GoldChecker goldChecker = new GoldChecker( "t087" );
65+
class t087 {
66+
public static final GoldChecker goldChecker = new GoldChecker("t087");
7067

71-
public static void main(String[] argv)
72-
{
68+
public static void main(String[] argv) {
7369
File f;
74-
if (argv.length < 2 || !argv[0].equals("-WorkDir"))
75-
f = new File(".", "foo.class");
76-
else
77-
f = new File(argv[1], "foo.class");
78-
if(f.isFile())
79-
{
80-
70+
if (argv.length < 2 || !argv[0].equals("-WorkDir")) {
71+
f = new File(".", "foo.class");
72+
} else {
73+
f = new File(argv[1], "foo.class");
74+
}
75+
if (f.isFile()) {
8176
f.delete();
8277

83-
for(int i = 1; i <= 2; i += 1)
84-
{
85-
try
86-
{
78+
for (int i = 1; i <= 2; i += 1) {
79+
try {
8780
foo.bar();
88-
}
89-
catch(Throwable t)
90-
{
81+
} catch (Throwable t) {
9182
t087.goldChecker.println("Exception on try" + i);
9283
}
9384
}
9485

95-
}
96-
else
86+
} else {
9787
t087.goldChecker.println("No foo.class in cwd");
88+
}
9889
t087.goldChecker.check();
9990
}
10091
}
92+
Lines changed: 23 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2008, 2020, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -36,14 +36,14 @@
3636
*
3737
* @comment make sure foo.class is only in the current directory
3838
* @clean jit.t.t088.foo
39-
* @run driver PropertyResolvingWrapper ExecDriver --cmd
39+
* @run driver ExecDriver --cmd
4040
* ${compile.jdk}/bin/javac
4141
* -d .
4242
* -cp ${test.class.path}
4343
* ${test.src}/t088.java
4444
*
4545
* @comment run the test
46-
* @run driver PropertyResolvingWrapper ExecDriver --java
46+
* @run driver ExecDriver --java
4747
* -cp .${path.separator}${test.class.path}
4848
* -Dtest.src=${test.src}
4949
* jit.t.t088.t088
@@ -55,55 +55,45 @@
5555
// Just like the one before except that the two patched calls
5656
// are attempted from distinct call sites.
5757

58-
import java.io.File;
59-
import nsk.share.TestFailure;
6058
import nsk.share.GoldChecker;
6159

62-
class foo
63-
{
64-
static void bar()
65-
{
60+
import java.io.File;
61+
62+
class foo {
63+
static void bar() {
6664
t088.goldChecker.println("You shouldn't see this.");
6765
}
6866
}
6967

70-
class t088
71-
{
72-
public static final GoldChecker goldChecker = new GoldChecker( "t088" );
68+
class t088 {
69+
public static final GoldChecker goldChecker = new GoldChecker("t088");
7370

74-
public static void main(String[] argv)
75-
{
71+
public static void main(String[] argv) {
7672
File f;
77-
if (argv.length < 2 || !argv[0].equals("-WorkDir"))
78-
f = new File(".", "foo.class");
79-
else
80-
f = new File(argv[1], "foo.class");
81-
if(f.isFile())
82-
{
83-
73+
if (argv.length < 2 || !argv[0].equals("-WorkDir")) {
74+
f = new File(".", "foo.class");
75+
} else {
76+
f = new File(argv[1], "foo.class");
77+
}
78+
if (f.isFile()) {
8479
f.delete();
8580

86-
try
87-
{
81+
try {
8882
foo.bar();
89-
}
90-
catch(Throwable t)
91-
{
83+
} catch (Throwable t) {
9284
t088.goldChecker.println("Exception on first try");
9385
}
9486

95-
try
96-
{
87+
try {
9788
foo.bar();
98-
}
99-
catch(Throwable t)
100-
{
89+
} catch (Throwable t) {
10190
t088.goldChecker.println("Exception on second try");
10291
}
10392

104-
}
105-
else
93+
} else {
10694
t088.goldChecker.println("No foo.class in cwd");
95+
}
10796
t088.goldChecker.check();
10897
}
10998
}
99+

0 commit comments

Comments
 (0)