mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 15:53:19 +00:00
Minor, rename codegen tests on platformName and platformStatic
This commit is contained in:
28
compiler/testData/codegen/boxWithJava/jvmStatic/annotations/Test.java
vendored
Normal file
28
compiler/testData/codegen/boxWithJava/jvmStatic/annotations/Test.java
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
import java.lang.String;
|
||||
import java.lang.annotation.Annotation;
|
||||
|
||||
class Test {
|
||||
|
||||
public static String test1() throws NoSuchMethodException {
|
||||
Annotation[] test1s = A.class.getMethod("test1").getAnnotations();
|
||||
for (Annotation test : test1s) {
|
||||
String name = test.toString();
|
||||
if (name.contains("testAnnotation")) {
|
||||
return "OK";
|
||||
}
|
||||
}
|
||||
return "fail";
|
||||
}
|
||||
|
||||
public static String test2() throws NoSuchMethodException {
|
||||
Annotation[] test2s = B.class.getMethod("test1").getAnnotations();
|
||||
for (Annotation test : test2s) {
|
||||
String name = test.toString();
|
||||
if (name.contains("testAnnotation")) {
|
||||
return "OK";
|
||||
}
|
||||
}
|
||||
return "fail";
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user