8221398: Move test NoClassDefFoundMsg.java to subdir exceptionMsgs/

Reviewed-by: coleenp
This commit is contained in:
Goetz Lindenmaier 2019-03-28 09:15:41 +01:00
parent caa5387a57
commit 2da45f12f2
2 changed files with 7 additions and 7 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -28,18 +28,18 @@
* @library /test/lib
* @modules java.base/jdk.internal.misc
* java.compiler
* @run main/native NoClassDefFoundMsg
* @run main/native NoClassDefFoundErrorTest
*/
import jdk.test.lib.compiler.InMemoryJavaCompiler;
import jdk.internal.misc.Unsafe;
public class NoClassDefFoundMsg {
public class NoClassDefFoundErrorTest {
static native void callDefineClass(String className);
static native void callFindClass(String className);
static {
System.loadLibrary("NoClassDefFoundMsg");
System.loadLibrary("NoClassDefFoundErrorTest");
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -24,13 +24,13 @@
#include <jni.h>
JNIEXPORT void JNICALL
Java_NoClassDefFoundMsg_callDefineClass(JNIEnv *env, jclass klass, jstring className) {
Java_NoClassDefFoundErrorTest_callDefineClass(JNIEnv *env, jclass klass, jstring className) {
const char *c_name = (*env)->GetStringUTFChars(env, className, NULL);
(*env)->DefineClass(env, c_name, NULL, NULL, 0);
}
JNIEXPORT void JNICALL
Java_NoClassDefFoundMsg_callFindClass(JNIEnv *env, jclass klass, jstring className) {
Java_NoClassDefFoundErrorTest_callFindClass(JNIEnv *env, jclass klass, jstring className) {
const char *c_name;
jclass cls;
if (className == NULL) {