Motion Matching: Enable test builds in CMakeLists.txt

Signed-off-by: Benjamin Jillich <jillich@amazon.com>
monroegm-disable-blank-issue-2
Benjamin Jillich 4 years ago
parent 1e11df5d92
commit 3e59c10e64

@ -99,57 +99,49 @@ endif()
################################################################################ ################################################################################
# See if globally, tests are supported # See if globally, tests are supported
if(PAL_TRAIT_BUILD_TESTS_SUPPORTED) if(PAL_TRAIT_BUILD_TESTS_SUPPORTED)
# We globally support tests, see if we support tests on this platform for MotionMatching.Static ly_add_target(
if(PAL_TRAIT_MOTIONMATCHING_TEST_SUPPORTED) NAME MotionMatching.Tests ${PAL_TRAIT_TEST_TARGET_TYPE}
# We support MotionMatching.Tests on this platform, add MotionMatching.Tests target which depends on MotionMatching.Static NAMESPACE Gem
ly_add_target( FILES_CMAKE
NAME MotionMatching.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} motionmatching_files.cmake
NAMESPACE Gem motionmatching_tests_files.cmake
FILES_CMAKE INCLUDE_DIRECTORIES
motionmatching_files.cmake PRIVATE
motionmatching_tests_files.cmake Tests
INCLUDE_DIRECTORIES Source
PRIVATE BUILD_DEPENDENCIES
Tests PRIVATE
Source AZ::AzTest
BUILD_DEPENDENCIES AZ::AzFramework
PRIVATE Gem::EMotionFX.Tests.Static
AZ::AzTest Gem::MotionMatching.Static
AZ::AzFramework )
Gem::EMotionFX.Tests.Static
Gem::MotionMatching.Static
)
# Add MotionMatching.Tests to googletest # Add MotionMatching.Tests to googletest
ly_add_googletest( ly_add_googletest(
NAME Gem::MotionMatching.Tests NAME Gem::MotionMatching.Tests
) )
endif() endif()
# If we are a host platform we want to add tools test like editor tests here # If we are a host platform we want to add tools test like editor tests here
if(PAL_TRAIT_BUILD_HOST_TOOLS) if(PAL_TRAIT_BUILD_HOST_TOOLS)
# We are a host platform, see if Editor tests are supported on this platform ly_add_target(
if(PAL_TRAIT_MOTIONMATCHING_EDITOR_TEST_SUPPORTED) NAME MotionMatching.Editor.Tests ${PAL_TRAIT_TEST_TARGET_TYPE}
# We support MotionMatching.Editor.Tests on this platform, add MotionMatching.Editor.Tests target which depends on MotionMatching.Editor NAMESPACE Gem
ly_add_target( FILES_CMAKE
NAME MotionMatching.Editor.Tests ${PAL_TRAIT_TEST_TARGET_TYPE} motionmatching_editor_tests_files.cmake
NAMESPACE Gem INCLUDE_DIRECTORIES
FILES_CMAKE PRIVATE
motionmatching_editor_tests_files.cmake Tests
INCLUDE_DIRECTORIES Source
PRIVATE BUILD_DEPENDENCIES
Tests PRIVATE
Source AZ::AzTest
BUILD_DEPENDENCIES Gem::MotionMatching.Editor
PRIVATE )
AZ::AzTest
Gem::MotionMatching.Editor
)
# Add MotionMatching.Editor.Tests to googletest # Add MotionMatching.Editor.Tests to googletest
ly_add_googletest( ly_add_googletest(
NAME Gem::MotionMatching.Editor.Tests NAME Gem::MotionMatching.Editor.Tests
) )
endif()
endif()
endif() endif()

Loading…
Cancel
Save