naiveproxy/components/cast_channel/BUILD.gn

108 lines
2.6 KiB
Plaintext
Raw Normal View History

2018-08-15 01:19:20 +03:00
# Copyright 2017 The Chromium 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("//testing/libfuzzer/fuzzer_test.gni")
static_library("cast_channel") {
sources = [
"cast_auth_util.cc",
"cast_auth_util.h",
"cast_channel_enum.cc",
"cast_channel_enum.h",
"cast_framer.cc",
"cast_framer.h",
"cast_message_handler.cc",
"cast_message_handler.h",
"cast_message_util.cc",
"cast_message_util.h",
"cast_socket.cc",
"cast_socket.h",
"cast_socket_service.cc",
"cast_socket_service.h",
"cast_transport.cc",
"cast_transport.h",
"keep_alive_delegate.cc",
"keep_alive_delegate.h",
"logger.cc",
"logger.h",
]
deps = [
"//base",
"//components/cast_certificate",
"//components/cast_channel/proto:cast_channel_proto",
"//components/keyed_service/content",
"//components/keyed_service/core",
"//components/prefs",
"//components/version_info",
"//content/public/browser",
"//content/public/common",
"//crypto",
"//net",
]
}
static_library("test_support") {
testonly = true
sources = [
"cast_test_util.cc",
"cast_test_util.h",
]
deps = [
":cast_channel",
"//base",
"//components/cast_channel/proto:cast_channel_proto",
"//net",
"//net:test_support",
"//testing/gmock",
"//testing/gtest",
]
}
source_set("unit_tests") {
testonly = true
sources = [
"cast_auth_util_unittest.cc",
"cast_framer_unittest.cc",
"cast_message_handler_unittest.cc",
"cast_message_util_unittest.cc",
"cast_socket_service_unittest.cc",
"cast_socket_unittest.cc",
"cast_transport_unittest.cc",
"keep_alive_delegate_unittest.cc",
"logger_unittest.cc",
]
deps = [
":cast_channel",
":test_support",
"//base/test:test_support",
"//components/cast_certificate",
"//components/cast_certificate:test_support",
"//components/cast_certificate/proto:unittest_proto",
"//components/cast_channel/proto:cast_channel_proto",
"//components/prefs",
"//components/prefs:test_support",
"//content/test:test_support",
"//net:test_support",
"//testing/gmock",
"//testing/gtest",
]
}
fuzzer_test("cast_message_fuzzer") {
sources = [
"cast_message_fuzzer.cc",
]
deps = [
":test_support",
"//base",
"//components/cast_channel",
"//components/cast_channel/proto:cast_channel_proto",
"//net",
]
seed_corpus = "fuzz_corpus"
# See MessageFramer::MessageHeader::max_message_size()
libfuzzer_options = [ "max_len=65535" ]
}