CMake/Tests/RunCMake/VSSolution/StartupProjectUseFolders-check.cmake
Taylor Braun-Jones f069be0548 VS: Fix default target support for targets nested inside a folder
It's not actually the first target in a `.sln` file that is treated as
the default startup project, but rather the first fully defined target.
2016-03-23 13:22:15 -04:00

10 lines
360 B
CMake

getProjectNames(projects)
list(GET projects 0 first_project)
if(NOT first_project STREQUAL "CMakePredefinedTargets")
error("CMakePredefinedTargets is not the first project")
endif()
list(GET projects 1 second_project)
if(NOT second_project STREQUAL "TestStartup")
error("TestStartup does not immediately follow the CMakePredefinedTargets project")
endif()