summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-06-25 18:37:38 (GMT)
committerBrad King <brad.king@kitware.com>2019-06-25 21:23:34 (GMT)
commit2ba5c37b3fed00ecc307b1d93780acd4a57695eb (patch)
tree9e2f2562b8c4bb12d1af62488934d293aac5eab8 /Tests/RunCMake
parent5c7880956f9b3daea561c7bf817b27aa47b53dd0 (diff)
downloadCMake-2ba5c37b3fed00ecc307b1d93780acd4a57695eb.zip
CMake-2ba5c37b3fed00ecc307b1d93780acd4a57695eb.tar.gz
CMake-2ba5c37b3fed00ecc307b1d93780acd4a57695eb.tar.bz2
export: Restore support for empty TARGETS list
Refactoring in commit f5acecaa6f (cmExportCommand: Port to cmArgumentParser, 2019-03-23, v3.15.0-rc1~270^2~3) broke the `export` command's support for specifying `TARGETS` with no entries. Fix it and add a test case. Fixes: #19415
Diffstat (limited to 'Tests/RunCMake')
-rw-r--r--Tests/RunCMake/export/Empty.cmake1
-rw-r--r--Tests/RunCMake/export/RunCMakeTest.cmake1
2 files changed, 2 insertions, 0 deletions
diff --git a/Tests/RunCMake/export/Empty.cmake b/Tests/RunCMake/export/Empty.cmake
new file mode 100644
index 0000000..2198ddf
--- /dev/null
+++ b/Tests/RunCMake/export/Empty.cmake
@@ -0,0 +1 @@
+export(TARGETS FILE targets.cmake)
diff --git a/Tests/RunCMake/export/RunCMakeTest.cmake b/Tests/RunCMake/export/RunCMakeTest.cmake
index 46bb1fc..97a0ca6 100644
--- a/Tests/RunCMake/export/RunCMakeTest.cmake
+++ b/Tests/RunCMake/export/RunCMakeTest.cmake
@@ -1,6 +1,7 @@
include(RunCMake)
run_cmake(CustomTarget)
+run_cmake(Empty)
run_cmake(TargetNotFound)
run_cmake(AppendExport)
run_cmake(OldIface)