1 /*
2 * Copyright 2021 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 /*
18 * Generated mock file from original source file
19 * Functions generated:10
20 */
21
22 #include <map>
23 #include <string>
24
25 extern std::map<std::string, int> mock_function_count_map;
26
27 #include <base/bind.h>
28 #include <cstring>
29 #include "bt_target.h"
30 #include "bta/sys/bta_sys.h"
31 #include "bta/sys/bta_sys_int.h"
32 #include "include/hardware/bluetooth.h"
33 #include "osi/include/alarm.h"
34 #include "osi/include/allocator.h"
35 #include "osi/include/log.h"
36 #include "stack/include/bt_types.h"
37 #include "stack/include/btu.h"
38
39 #ifndef UNUSED_ATTR
40 #define UNUSED_ATTR
41 #endif
42
bta_sys_is_register(uint8_t id)43 bool bta_sys_is_register(uint8_t id) {
44 mock_function_count_map[__func__]++;
45 return false;
46 }
BTA_sys_signal_hw_error()47 void BTA_sys_signal_hw_error() { mock_function_count_map[__func__]++; }
bta_set_forward_hw_failures(bool value)48 void bta_set_forward_hw_failures(bool value) {
49 mock_function_count_map[__func__]++;
50 }
bta_sys_deregister(uint8_t id)51 void bta_sys_deregister(uint8_t id) { mock_function_count_map[__func__]++; }
bta_sys_disable()52 void bta_sys_disable() { mock_function_count_map[__func__]++; }
bta_sys_init(void)53 void bta_sys_init(void) { mock_function_count_map[__func__]++; }
bta_sys_register(uint8_t id,const tBTA_SYS_REG * p_reg)54 void bta_sys_register(uint8_t id, const tBTA_SYS_REG* p_reg) {
55 mock_function_count_map[__func__]++;
56 }
bta_sys_sendmsg(void * p_msg)57 void bta_sys_sendmsg(void* p_msg) { mock_function_count_map[__func__]++; }
bta_sys_sendmsg_delayed(void * p_msg,const base::TimeDelta & delay)58 void bta_sys_sendmsg_delayed(void* p_msg, const base::TimeDelta& delay) {
59 mock_function_count_map[__func__]++;
60 }
bta_sys_start_timer(alarm_t * alarm,uint64_t interval_ms,uint16_t event,uint16_t layer_specific)61 void bta_sys_start_timer(alarm_t* alarm, uint64_t interval_ms, uint16_t event,
62 uint16_t layer_specific) {
63 mock_function_count_map[__func__]++;
64 }
65