OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef DEVICE_BLUETOOTH_TEST_BLUETOOTH_TEST_ANDROID_H_ | 5 #ifndef DEVICE_BLUETOOTH_TEST_BLUETOOTH_TEST_ANDROID_H_ |
6 #define DEVICE_BLUETOOTH_TEST_BLUETOOTH_TEST_ANDROID_H_ | 6 #define DEVICE_BLUETOOTH_TEST_BLUETOOTH_TEST_ANDROID_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/android/scoped_java_ref.h" | 10 #include "base/android/scoped_java_ref.h" |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 JNIEnv* env, | 111 JNIEnv* env, |
112 const base::android::JavaParamRef<jobject>& caller, | 112 const base::android::JavaParamRef<jobject>& caller, |
113 const base::android::JavaParamRef<jbyteArray>& value); | 113 const base::android::JavaParamRef<jbyteArray>& value); |
114 | 114 |
115 // Records that Java FakeBluetoothGatt writeDescriptor was called. | 115 // Records that Java FakeBluetoothGatt writeDescriptor was called. |
116 void OnFakeBluetoothGattWriteDescriptor( | 116 void OnFakeBluetoothGattWriteDescriptor( |
117 JNIEnv* env, | 117 JNIEnv* env, |
118 const base::android::JavaParamRef<jobject>& caller, | 118 const base::android::JavaParamRef<jobject>& caller, |
119 const base::android::JavaParamRef<jbyteArray>& value); | 119 const base::android::JavaParamRef<jbyteArray>& value); |
120 | 120 |
| 121 // Records that Java FakeBluetoothAdapter onAdapterStateChanged was called. |
| 122 void OnFakeAdapterStateChanged( |
| 123 JNIEnv* env, |
| 124 const base::android::JavaParamRef<jobject>& caller, |
| 125 const bool powered); |
| 126 |
121 base::android::ScopedJavaGlobalRef<jobject> j_fake_bluetooth_adapter_; | 127 base::android::ScopedJavaGlobalRef<jobject> j_fake_bluetooth_adapter_; |
122 | 128 |
123 int gatt_open_connections_ = 0; | 129 int gatt_open_connections_ = 0; |
124 }; | 130 }; |
125 | 131 |
126 // Defines common test fixture name. Use TEST_F(BluetoothTest, YourTestName). | 132 // Defines common test fixture name. Use TEST_F(BluetoothTest, YourTestName). |
127 typedef BluetoothTestAndroid BluetoothTest; | 133 typedef BluetoothTestAndroid BluetoothTest; |
128 | 134 |
129 } // namespace device | 135 } // namespace device |
130 | 136 |
131 #endif // DEVICE_BLUETOOTH_TEST_BLUETOOTH_TEST_ANDROID_H_ | 137 #endif // DEVICE_BLUETOOTH_TEST_BLUETOOTH_TEST_ANDROID_H_ |
OLD | NEW |