xref: /aosp_15_r20/art/test/661-oat-writer-layout/src/Test.java (revision 795d594fd825385562da6b089ea9b2033f3abf5a)
1*795d594fSAndroid Build Coastguard Worker // Copyright (C) 2017 The Android Open Source Project
2*795d594fSAndroid Build Coastguard Worker //
3*795d594fSAndroid Build Coastguard Worker // Licensed under the Apache License, Version 2.0 (the "License");
4*795d594fSAndroid Build Coastguard Worker // you may not use this file except in compliance with the License.
5*795d594fSAndroid Build Coastguard Worker // You may obtain a copy of the License at
6*795d594fSAndroid Build Coastguard Worker //
7*795d594fSAndroid Build Coastguard Worker //     http://www.apache.org/licenses/LICENSE-2.0
8*795d594fSAndroid Build Coastguard Worker //
9*795d594fSAndroid Build Coastguard Worker // Unless required by applicable law or agreed to in writing, software
10*795d594fSAndroid Build Coastguard Worker // distributed under the License is distributed on an "AS IS" BASIS,
11*795d594fSAndroid Build Coastguard Worker // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12*795d594fSAndroid Build Coastguard Worker // See the License for the specific language governing permissions and
13*795d594fSAndroid Build Coastguard Worker // limitations under the License.
14*795d594fSAndroid Build Coastguard Worker 
15*795d594fSAndroid Build Coastguard Worker import java.lang.reflect.Method;
16*795d594fSAndroid Build Coastguard Worker import java.util.ArrayList;
17*795d594fSAndroid Build Coastguard Worker 
18*795d594fSAndroid Build Coastguard Worker public class Test {
19*795d594fSAndroid Build Coastguard Worker   // Returns list of all methods in Generated.java
20*795d594fSAndroid Build Coastguard Worker   // This is to avoid having to introspect classes with extra code
21*795d594fSAndroid Build Coastguard Worker   // (for example, we ignore <init> methods).
getTestMethods()22*795d594fSAndroid Build Coastguard Worker   public static Method[] getTestMethods() throws NoSuchMethodException, SecurityException {
23*795d594fSAndroid Build Coastguard Worker     ArrayList<Method> all_methods = new ArrayList<Method>();
24*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_a$$$"));
25*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_a$$Startup$"));
26*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_a$Hot$Startup$"));
27*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_a$$$Poststartup"));
28*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_a$Hot$$Poststartup"));
29*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_a$$Startup$Poststartup"));
30*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_a$Hot$Startup$Poststartup"));
31*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_b$$$"));
32*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_b$$Startup$"));
33*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_b$Hot$Startup$"));
34*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_b$$$Poststartup"));
35*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_b$Hot$$Poststartup"));
36*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_b$$Startup$Poststartup"));
37*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_b$Hot$Startup$Poststartup"));
38*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_c$$$"));
39*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_c$$Startup$"));
40*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_c$Hot$Startup$"));
41*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_c$$$Poststartup"));
42*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_c$Hot$$Poststartup"));
43*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_c$$Startup$Poststartup"));
44*795d594fSAndroid Build Coastguard Worker     all_methods.add(A.class.getDeclaredMethod("m_c$Hot$Startup$Poststartup"));
45*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_a$$$"));
46*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_a$$Startup$"));
47*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_a$Hot$Startup$"));
48*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_a$$$Poststartup"));
49*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_a$Hot$$Poststartup"));
50*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_a$$Startup$Poststartup"));
51*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_a$Hot$Startup$Poststartup"));
52*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_b$$$"));
53*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_b$$Startup$"));
54*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_b$Hot$Startup$"));
55*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_b$$$Poststartup"));
56*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_b$Hot$$Poststartup"));
57*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_b$$Startup$Poststartup"));
58*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_b$Hot$Startup$Poststartup"));
59*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_c$$$"));
60*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_c$$Startup$"));
61*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_c$Hot$Startup$"));
62*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_c$$$Poststartup"));
63*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_c$Hot$$Poststartup"));
64*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_c$$Startup$Poststartup"));
65*795d594fSAndroid Build Coastguard Worker     all_methods.add(B.class.getDeclaredMethod("m_c$Hot$Startup$Poststartup"));
66*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_a$$$"));
67*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_a$$Startup$"));
68*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_a$Hot$Startup$"));
69*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_a$$$Poststartup"));
70*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_a$Hot$$Poststartup"));
71*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_a$$Startup$Poststartup"));
72*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_a$Hot$Startup$Poststartup"));
73*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_b$$$"));
74*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_b$$Startup$"));
75*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_b$Hot$Startup$"));
76*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_b$$$Poststartup"));
77*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_b$Hot$$Poststartup"));
78*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_b$$Startup$Poststartup"));
79*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_b$Hot$Startup$Poststartup"));
80*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_c$$$"));
81*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_c$$Startup$"));
82*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_c$Hot$Startup$"));
83*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_c$$$Poststartup"));
84*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_c$Hot$$Poststartup"));
85*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_c$$Startup$Poststartup"));
86*795d594fSAndroid Build Coastguard Worker     all_methods.add(C.class.getDeclaredMethod("m_c$Hot$Startup$Poststartup"));
87*795d594fSAndroid Build Coastguard Worker     return all_methods.toArray(new Method[all_methods.size()]);
88*795d594fSAndroid Build Coastguard Worker   }
89*795d594fSAndroid Build Coastguard Worker }
90*795d594fSAndroid Build Coastguard Worker 
91