Skip to content

Commit 7ce2692

Browse files
committed
test: remove stdlib unittest dependency for tests
When building without the standard library, we exclude the standard library from the test dependencies. The unittest framework is dependency on the standard library and cannot be built without it. Remove this dependency in that case as well.
1 parent b4d2f8a commit 7ce2692

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

test/CMakeLists.txt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -474,9 +474,11 @@ foreach(SDK ${SWIFT_SDKS})
474474
list(APPEND test_dependencies "touch-covering-tests")
475475
endif()
476476

477-
list(APPEND test_dependencies
478-
"swiftStdlibCollectionUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}"
479-
"swiftStdlibUnicodeUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}")
477+
if(SWIFT_BUILD_STDLIB)
478+
list(APPEND test_dependencies
479+
"swiftStdlibCollectionUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}"
480+
"swiftStdlibUnicodeUnittest-${SWIFT_SDK_${SDK}_LIB_SUBDIR}")
481+
endif()
480482

481483
set(validation_test_dependencies)
482484

0 commit comments

Comments
 (0)