Tests: Simplify RunCMake.ExcludeFromAll single-config case

Also avoid using parts of an unrelated test (NinjaMultiConfig)
that were not designed for use with all generators.
diff --git a/Tests/RunCMake/ExcludeFromAll/RunCMakeTest.cmake b/Tests/RunCMake/ExcludeFromAll/RunCMakeTest.cmake
index 25201e4..2b4fc89 100644
--- a/Tests/RunCMake/ExcludeFromAll/RunCMakeTest.cmake
+++ b/Tests/RunCMake/ExcludeFromAll/RunCMakeTest.cmake
@@ -9,7 +9,7 @@
         -DCMAKE_BUILD_TYPE=${config}
         -DTOOL_EXCLUDE_FROM_ALL=${exclude_from_all_value})
     set(RunCMake_TEST_NO_CLEAN 1)
-    include(${RunCMake_TEST_BINARY_DIR}/target_files.cmake)
+    include(${RunCMake_TEST_BINARY_DIR}/target_files_${config}.cmake)
     run_cmake_command(${case}-build ${CMAKE_COMMAND} --build . --config ${config})
 endfunction()
 
diff --git a/Tests/RunCMake/ExcludeFromAll/single-config.cmake b/Tests/RunCMake/ExcludeFromAll/single-config.cmake
index 71a9f06..aa49c21 100644
--- a/Tests/RunCMake/ExcludeFromAll/single-config.cmake
+++ b/Tests/RunCMake/ExcludeFromAll/single-config.cmake
@@ -2,10 +2,6 @@
 add_executable(tool main.c)
 set_property(TARGET tool PROPERTY EXCLUDE_FROM_ALL "${TOOL_EXCLUDE_FROM_ALL}")
 
-include(../NinjaMultiConfig/Common.cmake)
-set(orig_CMAKE_CONFIGURATION_TYPES ${CMAKE_CONFIGURATION_TYPES})
-if("${CMAKE_CONFIGURATION_TYPES}" STREQUAL "")
-    set(CMAKE_CONFIGURATION_TYPES ${CMAKE_BUILD_TYPE})
-endif()
-generate_output_files(tool)
-set(CMAKE_CONFIGURATION_TYPES ${orig_CMAKE_CONFIGURATION_TYPES})
+file(GENERATE OUTPUT "${CMAKE_BINARY_DIR}/target_files_$<CONFIG>.cmake" CONTENT [[
+set(TARGET_FILE_tool_$<CONFIG> [==[$<TARGET_FILE:tool>]==])
+]])