1 /*
2  * Copyright (C) 2017 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #include "oatdump_test.h"
18 
19 namespace art {
20 
21 // Disable tests on arm and arm64 as they are taking too long to run. b/27824283.
22 #define TEST_DISABLED_FOR_ARM_AND_ARM64() \
23   TEST_DISABLED_FOR_ARM();                \
24   TEST_DISABLED_FOR_ARM64();
25 
TEST_P(OatDumpTest,TestDumpImage)26 TEST_P(OatDumpTest, TestDumpImage) {
27   TEST_DISABLED_FOR_RISCV64();
28   TEST_DISABLED_FOR_ARM_AND_ARM64();
29   // TODO(b/334200225): Temporarily disable this test case for x86 and x86_64
30   // till the disassembler issue is fixed.
31   TEST_DISABLED_FOR_X86();
32   TEST_DISABLED_FOR_X86_64();
33   std::string error_msg;
34   ASSERT_TRUE(
35       Exec(GetParam(), kArgImage | kArgBcp | kArgIsa, {}, kExpectImage | kExpectOat | kExpectCode));
36 }
37 
TEST_P(OatDumpTest,TestDumpOatBcp)38 TEST_P(OatDumpTest, TestDumpOatBcp) {
39   TEST_DISABLED_FOR_RISCV64();
40   TEST_DISABLED_FOR_ARM_AND_ARM64();
41   std::string error_msg;
42   ASSERT_TRUE(Exec(GetParam(), kArgOatBcp | kArgDexBcp, {}, kExpectOat | kExpectCode));
43 }
44 
45 }  // namespace art
46