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

Loading…
Cancel
Save