mirror of
https://github.com/weechat/weechat.git
synced 2026-07-01 15:26:37 +02:00
68d87f2b80
This commit introduces fuzz testing, for now on core functions, with 4 new targets that are built on demand with CMake option `ENABLE_FUZZ` (build of these tests is disabled by default): - weechat_core_calc_fuzzer - weechat_core_crypto_fuzzer - weechat_core_string_fuzzer - weechat_core_utf8_fuzzer
38 lines
1.1 KiB
CMake
38 lines
1.1 KiB
CMake
#
|
|
# SPDX-FileCopyrightText: 2014-2025 Sébastien Helleu <flashcode@flashtux.org>
|
|
#
|
|
# SPDX-License-Identifier: GPL-3.0-or-later
|
|
#
|
|
# This file is part of WeeChat, the extensible chat client.
|
|
#
|
|
# WeeChat is free software; you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation; either version 3 of the License, or
|
|
# (at your option) any later version.
|
|
#
|
|
# WeeChat is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU General Public License for more details.
|
|
#
|
|
# You should have received a copy of the GNU General Public License
|
|
# along with WeeChat. If not, see <https://www.gnu.org/licenses/>.
|
|
#
|
|
|
|
if(ENABLE_FUZZ)
|
|
add_subdirectory(fuzz)
|
|
endif()
|
|
|
|
if(ENABLE_TESTS)
|
|
find_package(CppUTest)
|
|
if(CPPUTEST_FOUND)
|
|
enable_testing()
|
|
add_subdirectory(unit)
|
|
else()
|
|
message(SEND_ERROR "CppUTest not found")
|
|
endif()
|
|
else()
|
|
enable_testing()
|
|
add_test(NAME notests COMMAND true)
|
|
endif()
|