1// Copyright 2024 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 15package { 16 default_applicable_licenses: ["Android-Apache-2.0"], 17} 18 19// Helps httplib2 find ca certs in python targets with embedded launcher. 20python_library_host { 21 name: "ca_certs_locater", 22 srcs: [ 23 "ca_certs_locater.py", 24 ], 25} 26 27python_defaults { 28 name: "ca_certs_locater_unittest_default", 29 srcs: [ 30 "ca_certs_locater_unittest.py", 31 ], 32 main: "ca_certs_locater_unittest.py", 33 libs: [ 34 "py-httplib2", 35 "ca_certs_locater", 36 ], 37} 38 39python_test_host { 40 name: "ca_certs_locater_unittest", 41 defaults: ["ca_certs_locater_unittest_default"], 42 test_options: { 43 unit_test: true, 44 }, 45 version: { 46 py3: { 47 embedded_launcher: true, 48 }, 49 }, 50} 51 52python_test_host { 53 name: "ca_certs_locater_non_embedded_unittest", 54 defaults: ["ca_certs_locater_unittest_default"], 55 test_options: { 56 unit_test: true, 57 }, 58 version: { 59 py3: { 60 embedded_launcher: false, 61 }, 62 }, 63} 64