Add a test that all //api/test headers are compilable.

Bug: webrtc:10376
Change-Id: I2a1ea24ddf5980c76660724fae68c16179bb25a7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/125682
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Yves Gerey <yvesg@google.com>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27119}
This commit is contained in:
Harald Alvestrand 2019-03-14 05:42:04 +01:00 committed by Commit Bot
parent d5e1c372c9
commit 3cc45d4467
3 changed files with 73 additions and 0 deletions

View File

@ -474,6 +474,7 @@ if (rtc_include_tests) {
deps = [ deps = [
":webrtc_common", ":webrtc_common",
"api:compile_all_headers",
"api:rtc_api_unittests", "api:rtc_api_unittests",
"api/audio/test:audio_api_unittests", "api/audio/test:audio_api_unittests",
"api/audio_codecs/test:audio_codecs_api_unittests", "api/audio_codecs/test:audio_codecs_api_unittests",

View File

@ -662,4 +662,31 @@ if (rtc_include_tests) {
"units:units_unittests", "units:units_unittests",
] ]
} }
rtc_source_set("compile_all_headers") {
testonly = true
sources = [
"test/compile_all_headers.cc",
]
deps = [
":fake_frame_decryptor",
":fake_frame_encryptor",
":fake_media_transport",
":loopback_media_transport",
":mock_audio_mixer",
":mock_frame_decryptor",
":mock_frame_encryptor",
":mock_peerconnectioninterface",
":mock_rtp",
":mock_video_bitrate_allocator",
":mock_video_bitrate_allocator_factory",
":mock_video_codec_factory",
":mock_video_decoder",
":mock_video_encoder",
":rtc_api_unittests",
"units:units_unittests",
]
}
} }

View File

@ -0,0 +1,45 @@
/*
* Copyright 2019 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
// This file verifies that all include files in this directory can be
// compiled without errors or other required includes.
// Note: The following header files are not not tested here, as their
// associated targets are not included in all configurations.
// "api/test/audioproc_float.h"
// "api/test/create_video_quality_test_fixture.h"
// "api/test/neteq_simulator_factory.h"
// "api/test/video_quality_test_fixture.h"
// The following header files are also not tested:
// "api/test/create_simulcast_test_fixture.h"
// "api/test/create_videocodec_test_fixture.h"
// "api/test/neteq_simulator.h"
// "api/test/simulated_network.h"
// "api/test/simulcast_test_fixture.h"
// "api/test/test_dependency_factory.h"
// "api/test/videocodec_test_fixture.h"
// "api/test/videocodec_test_stats.h"
#include "api/test/fake_frame_decryptor.h"
#include "api/test/fake_frame_encryptor.h"
#include "api/test/fake_media_transport.h"
#include "api/test/loopback_media_transport.h"
#include "api/test/mock_audio_mixer.h"
#include "api/test/mock_frame_decryptor.h"
#include "api/test/mock_frame_encryptor.h"
#include "api/test/mock_peerconnectioninterface.h"
#include "api/test/mock_rtpreceiver.h"
#include "api/test/mock_rtpsender.h"
#include "api/test/mock_video_bitrate_allocator.h"
#include "api/test/mock_video_bitrate_allocator_factory.h"
#include "api/test/mock_video_decoder.h"
#include "api/test/mock_video_decoder_factory.h"
#include "api/test/mock_video_encoder.h"
#include "api/test/mock_video_encoder_factory.h"