< prev index next >

test/hotspot/jtreg/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveMethodTest.java

Print this page
rev 50604 : imported patch jep181-rev1

*** 1,7 **** /* ! * Copyright (c) 2014, 2016, 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 * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. --- 1,7 ---- /* ! * Copyright (c) 2014, 2018, 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 * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation.
*** 37,46 **** --- 37,47 ---- import jdk.vm.ci.runtime.JVMCI; import org.junit.Test; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNull; + import static org.junit.Assert.assertNotNull; public class ResolvedJavaTypeResolveMethodTest { public final MetaAccessProvider metaAccess; public ResolvedJavaTypeResolveMethodTest() {
*** 115,126 **** ResolvedJavaType a = getType(A.class); ResolvedJavaType b = getType(B.class); ResolvedJavaType c = getType(C.class); ResolvedJavaMethod priv = getMethod(a, "priv"); ! assertNull(a.resolveMethod(priv, c)); ! assertNull(b.resolveMethod(priv, c)); } @Test public void testAbstractMethod() { ResolvedJavaType a = getType(A.class); --- 116,128 ---- ResolvedJavaType a = getType(A.class); ResolvedJavaType b = getType(B.class); ResolvedJavaType c = getType(C.class); ResolvedJavaMethod priv = getMethod(a, "priv"); ! // nestmates have access to private methods ! assertNotNull(a.resolveMethod(priv, c)); ! assertNotNull(b.resolveMethod(priv, c)); } @Test public void testAbstractMethod() { ResolvedJavaType a = getType(A.class);
< prev index next >