1// Copyright (C) 2019 The Android Open Source Project 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15// Separate asuite_metrics and asuite_cc_client libs to different tests, due to asuite_cc_client 16// also include asuite_metrics and other needed python files, in order to make sure asuite_metrics 17// tests result is accurate, separate them to two different test modules. 18 19// For testing asuite_metrics python2 libs 20python_test_host { 21 name: "asuite_metrics_lib_tests", 22 main: "asuite_lib_run_test.py", 23 // These tests primarily check that the metric libs can be imported properly (see b/132086641). 24 // Specify a different pkg_path so that we can properly test them in isolation. 25 pkg_path: "asuite_test", 26 srcs: [ 27 "asuite_lib_run_test.py", 28 "asuite_metrics_test.py", 29 ], 30 libs: [ 31 "asuite_metrics", 32 ], 33 test_suites: ["general-tests"], 34 defaults: ["atest_py2_default"], 35} 36 37// For testing asuite_metrics python3 libs 38python_test_host { 39 name: "asuite_metrics_lib_py3_tests", 40 main: "asuite_lib_run_test.py", 41 pkg_path: "asuite_test", 42 srcs: [ 43 "asuite_lib_run_test.py", 44 "asuite_metrics_test.py", 45 ], 46 libs: [ 47 "asuite_metrics", 48 ], 49 test_suites: ["general-tests"], 50 defaults: ["atest_lib_default"], 51} 52 53// For testing asuite_cc_client python2 libs 54python_test_host { 55 name: "asuite_cc_lib_tests", 56 main: "asuite_lib_run_test.py", 57 pkg_path: "asuite_test", 58 srcs: [ 59 "asuite_lib_run_test.py", 60 "asuite_cc_client_test.py", 61 ], 62 libs: [ 63 "asuite_cc_client", 64 ], 65 test_suites: ["general-tests"], 66 defaults: ["atest_py2_default"], 67} 68 69// For testing asuite_cc_client python3 libs 70python_test_host { 71 name: "asuite_cc_lib_py3_tests", 72 main: "asuite_lib_run_test.py", 73 pkg_path: "asuite_test", 74 srcs: [ 75 "asuite_lib_run_test.py", 76 "asuite_cc_client_test.py", 77 ], 78 libs: [ 79 "asuite_cc_client", 80 ], 81 test_suites: ["general-tests"], 82 defaults: ["atest_lib_default"], 83} 84