Skip to content

Commit 2ffa226

Browse files
committed
Fix comments
1 parent d03ff51 commit 2ffa226

File tree

2 files changed

+32
-21
lines changed

2 files changed

+32
-21
lines changed

CMakeLists.txt

Lines changed: 2 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ option(EXECUTORCH_BUILD_KERNELS_QUANTIZED "Build the quantized kernels" OFF)
214214

215215
option(EXECUTORCH_BUILD_DEVTOOLS "Build the ExecuTorch Developer Tools")
216216

217-
option(EXECUTORCH_BUILD_TESTS "Build CMake-based unit tests" ON)
217+
option(EXECUTORCH_BUILD_TESTS "Build CMake-based unit tests" OFF)
218218

219219
option(EXECUTORCH_NNLIB_OPT "Build Cadence backend Hifi nnlib kernel" OFF)
220220

@@ -833,26 +833,7 @@ if(EXECUTORCH_BUILD_VULKAN)
833833
add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/backends/vulkan)
834834
endif()
835835

836-
if(BUILD_TESTING)
837-
# This contains the list of tests which are always built
838-
add_subdirectory(extension/evalue_util/test)
839-
add_subdirectory(extension/kernel_util/test)
840-
add_subdirectory(extension/memory_allocator/test)
841-
add_subdirectory(extension/parallel/test)
842-
add_subdirectory(extension/pytree/test)
843-
add_subdirectory(kernels/portable/test)
844-
add_subdirectory(kernels/portable/cpu/util/test)
845-
add_subdirectory(kernels/prim_ops/test)
846-
add_subdirectory(kernels/test)
847-
add_subdirectory(runtime/core/exec_aten/testing_util/test)
848-
add_subdirectory(runtime/core/exec_aten/util/test)
849-
add_subdirectory(runtime/core/portable_type/test)
850-
add_subdirectory(runtime/core/test)
851-
add_subdirectory(runtime/executor/test)
852-
add_subdirectory(runtime/kernel/test)
853-
add_subdirectory(runtime/platform/test)
854-
add_subdirectory(test/utils)
855-
endif()
836+
include(Test.cmake)
856837

857838
# Print all summary
858839
executorch_print_configuration_summary()

Test.cmake

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Copyright (c) Meta Platforms, Inc. and affiliates.
2+
# All rights reserved.
3+
#
4+
# This source code is licensed under the BSD-style license found in the
5+
# LICENSE file in the root directory of this source tree.
6+
7+
#
8+
# A helper CMake file to trigger C++ unit tests.
9+
#
10+
11+
if(BUILD_TESTING)
12+
# This contains the list of tests which are always built
13+
add_subdirectory(extension/evalue_util/test)
14+
add_subdirectory(extension/kernel_util/test)
15+
add_subdirectory(extension/memory_allocator/test)
16+
add_subdirectory(extension/parallel/test)
17+
add_subdirectory(extension/pytree/test)
18+
add_subdirectory(kernels/portable/test)
19+
add_subdirectory(kernels/portable/cpu/util/test)
20+
add_subdirectory(kernels/prim_ops/test)
21+
add_subdirectory(kernels/test)
22+
add_subdirectory(runtime/core/exec_aten/testing_util/test)
23+
add_subdirectory(runtime/core/exec_aten/util/test)
24+
add_subdirectory(runtime/core/portable_type/test)
25+
add_subdirectory(runtime/core/test)
26+
add_subdirectory(runtime/executor/test)
27+
add_subdirectory(runtime/kernel/test)
28+
add_subdirectory(runtime/platform/test)
29+
add_subdirectory(test/utils)
30+
endif()

0 commit comments

Comments
 (0)