Re: RFR: 8287171: Refactor null caller tests to a single directory [v3]
On Mon, 30 May 2022 00:10:50 GMT, Tim Prinzing wrote: >> Created a test at test/jdk/jdk/nullCaller called NullCallerTest that creates >> a test module with some resources in it for the actual tests that occur at >> the native level. The native part was switched to c++ instead of c to make >> it easier to create helper objects that reduce the redundant code performing >> error checking. The two helper classes InstanceCall and StaticCall were >> placed in an include file called CallHelper.hpp. The main part of the tests >> are in exeNullCallerTest.cpp, and there is a separate function for each of >> the bug reports. > > Tim Prinzing has updated the pull request incrementally with one additional > commit since the last revision: > > problem with iostream on Windows, use printf test/jdk/jdk/nullCaller/CallHelper.hpp line 176: > 174: } > 175: > 176: // call an method returning an object checking for exceptions and `s/an method/a method/` test/jdk/jdk/nullCaller/exeNullCallerTest.cpp line 29: > 27: * ResourceBundle::getBundle may throw NPE when invoked by JNI code with > no caller frame > 28: */ > 29: void JDK_8280902(JNIEnv* env) { A descriptive method name would be more helpful than the bug ID, for example, `getResourceBundle` and `registerClassLoaderAsParallelCapable` test/jdk/jdk/nullCaller/exeNullCallerTest.cpp line 49: > 47: > 48: // check the message > 49: if (std::string("Hello!") != env->GetStringUTFChars(msg,NULL)) { nit: a space after the comma `(msg, NULL)` consistent with the format in this local file. - PR: https://git.openjdk.java.net/jdk/pull/8934
Re: RFR: 8287171: Refactor null caller tests to a single directory [v3]
On Mon, 30 May 2022 05:37:16 GMT, Alan Bateman wrote: > I don't think jdk/nullCaller is right location for this. Maybe jni/nullCaller > could work. You'll probably need to add the location to an appropriate > group/tier in test/jdk/TEST.groups, otherwise it won't be run. I also think `test/jdk/jni/nullCaller` is better. - PR: https://git.openjdk.java.net/jdk/pull/8934
Re: RFR: 8287171: Refactor null caller tests to a single directory [v3]
On Mon, 30 May 2022 00:10:50 GMT, Tim Prinzing wrote: >> Created a test at test/jdk/jdk/nullCaller called NullCallerTest that creates >> a test module with some resources in it for the actual tests that occur at >> the native level. The native part was switched to c++ instead of c to make >> it easier to create helper objects that reduce the redundant code performing >> error checking. The two helper classes InstanceCall and StaticCall were >> placed in an include file called CallHelper.hpp. The main part of the tests >> are in exeNullCallerTest.cpp, and there is a separate function for each of >> the bug reports. > > Tim Prinzing has updated the pull request incrementally with one additional > commit since the last revision: > > problem with iostream on Windows, use printf Build changes look good. - Marked as reviewed by ihse (Reviewer). PR: https://git.openjdk.java.net/jdk/pull/8934
Re: RFR: 8287171: Refactor null caller tests to a single directory [v3]
On Mon, 30 May 2022 00:10:50 GMT, Tim Prinzing wrote: >> Created a test at test/jdk/jdk/nullCaller called NullCallerTest that creates >> a test module with some resources in it for the actual tests that occur at >> the native level. The native part was switched to c++ instead of c to make >> it easier to create helper objects that reduce the redundant code performing >> error checking. The two helper classes InstanceCall and StaticCall were >> placed in an include file called CallHelper.hpp. The main part of the tests >> are in exeNullCallerTest.cpp, and there is a separate function for each of >> the bug reports. > > Tim Prinzing has updated the pull request incrementally with one additional > commit since the last revision: > > problem with iostream on Windows, use printf I don't think jdk/nullCaller is right location for this. Maybe jni/nullCaller could work. You'll probably need to add the location to an appropriate group/tier in test/jdk/TEST.groups, otherwise it won't be run. - PR: https://git.openjdk.java.net/jdk/pull/8934
Re: RFR: 8287171: Refactor null caller tests to a single directory [v3]
> Created a test at test/jdk/jdk/nullCaller called NullCallerTest that creates > a test module with some resources in it for the actual tests that occur at > the native level. The native part was switched to c++ instead of c to make it > easier to create helper objects that reduce the redundant code performing > error checking. The two helper classes InstanceCall and StaticCall were > placed in an include file called CallHelper.hpp. The main part of the tests > are in exeNullCallerTest.cpp, and there is a separate function for each of > the bug reports. Tim Prinzing has updated the pull request incrementally with one additional commit since the last revision: problem with iostream on Windows, use printf - Changes: - all: https://git.openjdk.java.net/jdk/pull/8934/files - new: https://git.openjdk.java.net/jdk/pull/8934/files/a54aa747..f1406a45 Webrevs: - full: https://webrevs.openjdk.java.net/?repo=jdk=8934=02 - incr: https://webrevs.openjdk.java.net/?repo=jdk=8934=01-02 Stats: 14 lines in 2 files changed: 8 ins; 2 del; 4 mod Patch: https://git.openjdk.java.net/jdk/pull/8934.diff Fetch: git fetch https://git.openjdk.java.net/jdk pull/8934/head:pull/8934 PR: https://git.openjdk.java.net/jdk/pull/8934