cc_library(
    name = "internal",
    srcs = [
        "ble_advertisement.cc",
        "bluetooth_device_name.cc",
        "internal_payload.cc",
        "internal_payload.h",
        "loop_runner.cc",
        "loop_runner.h",
        "offline_frames.cc",
        "wifi_lan_service_info.cc",
    ],
    hdrs = [
        "bandwidth_upgrade_handler.h",
        "bandwidth_upgrade_manager.cc",
        "bandwidth_upgrade_manager.h",
        "base_bandwidth_upgrade_handler.cc",
        "base_bandwidth_upgrade_handler.h",
        "base_endpoint_channel.cc",
        "base_endpoint_channel.h",
        "base_pcp_handler.cc",
        "base_pcp_handler.h",
        "ble_advertisement.h",
        "ble_compat.h",
        "ble_endpoint_channel.cc",
        "ble_endpoint_channel.h",
        "bluetooth_device_name.h",
        "bluetooth_endpoint_channel.cc",
        "bluetooth_endpoint_channel.h",
        "client_proxy.cc",
        "client_proxy.h",
        "encryption_runner.cc",
        "encryption_runner.h",
        "endpoint_channel.h",
        "endpoint_channel_manager.cc",
        "endpoint_channel_manager.h",
        "endpoint_manager.cc",
        "endpoint_manager.h",
        "internal_payload_factory.cc",
        "internal_payload_factory.h",
        "medium_manager.cc",
        "medium_manager.h",
        "offline_frames.h",
        "offline_service_controller.cc",
        "offline_service_controller.h",
        "p2p_cluster_pcp_handler.cc",
        "p2p_cluster_pcp_handler.h",
        "p2p_point_to_point_pcp_handler.cc",
        "p2p_point_to_point_pcp_handler.h",
        "p2p_star_pcp_handler.cc",
        "p2p_star_pcp_handler.h",
        "payload_manager.cc",
        "payload_manager.h",
        "pcp.h",
        "pcp_handler.h",
        "pcp_manager.cc",
        "pcp_manager.h",
        "service_controller.h",
        "service_controller_router.cc",
        "service_controller_router.h",
        "wifi_lan_service_info.h",
        "wifi_lan_upgrade_handler.cc",
        "wifi_lan_upgrade_handler.h",
    ],
    visibility = [
        "//core:__pkg__",
    ],
    deps = [
        "//core:types",
        "//core/internal/mediums",
        "//proto/connections:offline_wire_formats_portable_proto",
        "//platform:logging",
        "//platform:types",
        "//platform:utils",
        "//platform/api",
        "//platform/port:down_cast",
        "//platform/port:string",
        "//proto:connections_enums_portable_proto",
        "//net/proto2/compat/public:proto2_lite",
        "//securegcm:ukey2",
        "//absl/strings",
    ],
)

cc_test(
    name = "base_endpoint_channel_test",
    srcs = ["base_endpoint_channel_test.cc"],
    deps = [
        ":internal",
        "//platform:utils",
        "//platform/impl/default",
        "//proto:connections_enums_portable_proto",
        "//testing/base/public:gunit_main",
    ],
)

cc_test(
    name = "bluetooth_device_name_test",
    srcs = ["bluetooth_device_name_test.cc"],
    deps = [
        ":internal",
        "//platform:utils",
        "//platform/port:string",
        "//testing/base/public:gunit_main",
    ],
)

cc_test(
    name = "ble_advertisement_test",
    srcs = ["ble_advertisement_test.cc"],
    deps = [
        ":internal",
        "//platform/port:string",
        "//testing/base/public:gunit_main",
    ],
)

cc_test(
    name = "wifi_lan_service_info_test",
    srcs = ["wifi_lan_service_info_test.cc"],
    deps = [
        ":internal",
        "//platform:utils",
        "//platform/port:string",
        "//testing/base/public:gunit_main",
    ],
)

cc_test(
    name = "offline_frames_test",
    srcs = [
        "offline_frames_test.cc",
    ],
    deps = [
        ":internal",
        "//proto/connections:offline_wire_formats_portable_proto",
        "//platform:types",
        "//testing/base/public:gunit_main",
    ],
)
