summaryrefslogtreecommitdiffstats
path: root/bluetooth
diff options
context:
space:
mode:
authorYuexi Ma <yuexima@google.com>2017-02-28 18:15:17 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2017-02-28 18:15:18 +0000
commit5fd2ce668db31df297c81aca19c524b23fb6877f (patch)
tree9f99a5f9ca798844e844c3b9d8f05fc5bbc39e71 /bluetooth
parent4ba6a7d3ddc3ce828a69770545c28d6e5eeba248 (diff)
parent178dfd5e291ed78921bd0c21b4203ff75406ae04 (diff)
downloadandroid_hardware_interfaces-5fd2ce668db31df297c81aca19c524b23fb6877f.tar.gz
android_hardware_interfaces-5fd2ce668db31df297c81aca19c524b23fb6877f.tar.bz2
android_hardware_interfaces-5fd2ce668db31df297c81aca19c524b23fb6877f.zip
Merge "change all vts hidl tests to use VtsHalHidlTargetBaseTest"
Diffstat (limited to 'bluetooth')
-rw-r--r--bluetooth/1.0/vts/functional/Android.bp3
-rw-r--r--bluetooth/1.0/vts/functional/VtsHalBluetoothV1_0TargetTest.cpp6
2 files changed, 4 insertions, 5 deletions
diff --git a/bluetooth/1.0/vts/functional/Android.bp b/bluetooth/1.0/vts/functional/Android.bp
index 939a07f6a..a57a55aec 100644
--- a/bluetooth/1.0/vts/functional/Android.bp
+++ b/bluetooth/1.0/vts/functional/Android.bp
@@ -16,7 +16,6 @@
cc_test {
name: "VtsHalBluetoothV1_0TargetTest",
- gtest: true,
srcs: ["VtsHalBluetoothV1_0TargetTest.cpp"],
shared_libs: [
"libbase",
@@ -28,7 +27,7 @@ cc_test {
"libutils",
"android.hardware.bluetooth@1.0",
],
- static_libs: ["libgtest"],
+ static_libs: ["VtsHalHidlTargetBaseTest"],
cflags: [
"-O0",
"-g",
diff --git a/bluetooth/1.0/vts/functional/VtsHalBluetoothV1_0TargetTest.cpp b/bluetooth/1.0/vts/functional/VtsHalBluetoothV1_0TargetTest.cpp
index 5a6c29ac8..ce158750f 100644
--- a/bluetooth/1.0/vts/functional/VtsHalBluetoothV1_0TargetTest.cpp
+++ b/bluetooth/1.0/vts/functional/VtsHalBluetoothV1_0TargetTest.cpp
@@ -23,7 +23,7 @@
#include <hardware/bluetooth.h>
#include <utils/Log.h>
-#include <gtest/gtest.h>
+#include <VtsHalHidlTargetBaseTest.h>
#include <condition_variable>
#include <mutex>
#include <queue>
@@ -117,11 +117,11 @@ class ThroughputLogger {
};
// The main test class for Bluetooth HIDL HAL.
-class BluetoothHidlTest : public ::testing::Test {
+class BluetoothHidlTest : public ::testing::VtsHalHidlTargetBaseTest {
public:
virtual void SetUp() override {
// currently test passthrough mode only
- bluetooth = IBluetoothHci::getService();
+ bluetooth = testing::VtsHalHidlTargetBaseTest::getService<IBluetoothHci>();
ASSERT_NE(bluetooth, nullptr);
ALOGI("%s: getService() for bluetooth is %s", __func__,
bluetooth->isRemote() ? "remote" : "local");