| # Copyright 2018 The Fuchsia Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| import("//build/package.gni") |
| import("//build/test.gni") |
| import("//build/test/test_package.gni") |
| |
| static_library("inet") { |
| sources = [ |
| "ip_address.cc", |
| "ip_address.h", |
| "ip_port.cc", |
| "ip_port.h", |
| "socket_address.cc", |
| "socket_address.h", |
| ] |
| |
| public_deps = [ |
| "//sdk/fidl/fuchsia.netstack", |
| "//src/lib/fxl", |
| "//zircon/system/fidl/fuchsia-net", |
| ] |
| } |
| |
| test("tests_bin") { |
| output_name = "libinet_tests" |
| |
| sources = [ |
| "test/ip_address_test.cc", |
| "test/socket_address_test.cc", |
| ] |
| |
| deps = [ |
| ":inet", |
| "//src/lib/fxl/test:gtest_main", |
| ] |
| } |
| |
| test_package("libinet_tests") { |
| deps = [ ":tests_bin" ] |
| |
| tests = [ |
| { |
| name = "libinet_tests" |
| environments = basic_envs |
| }, |
| ] |
| } |
| |
| group("tests") { |
| testonly = true |
| |
| public_deps = [ ":libinet_tests" ] |
| } |