Index: tools/battor_agent/BUILD.gn |
diff --git a/tools/battor_agent/BUILD.gn b/tools/battor_agent/BUILD.gn |
index c808409973393e2cbf4105c6db9233f8538e498d..ba98b2d36659de35f482072b2f26acc9fc8e6c78 100644 |
--- a/tools/battor_agent/BUILD.gn |
+++ b/tools/battor_agent/BUILD.gn |
@@ -2,6 +2,8 @@ |
# Use of this source code is governed by a BSD-style license that can be |
# found in the LICENSE file. |
+import("//testing/test.gni") |
+ |
executable("battor_agent") { |
sources = [ |
"battor_agent_bin.cc", |
@@ -14,14 +16,32 @@ executable("battor_agent") { |
] |
} |
-static_library("battor_agent_lib") { |
+source_set("battor_agent_lib") { |
sources = [ |
"battor_agent.cc", |
"battor_agent.h", |
+ "battor_connection.cc", |
+ "battor_connection.h", |
"battor_error.h", |
] |
deps = [ |
"//base", |
"//device/serial", |
+ "//net", |
+ ] |
+} |
+ |
+test("battor_agent_unittests") { |
+ sources = [ |
+ "battor_connection_unittest.cc", |
+ ] |
+ deps = [ |
+ ":battor_agent_lib", |
+ "//base", |
+ "//base/test:run_all_unittests", |
+ "//device/serial", |
+ "//device/serial:test_support", |
+ "//mojo/public/c/system:for_shared_library", |
+ "//testing/gtest", |
] |
} |