summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake
diff options
context:
space:
mode:
authorCraig Scott <craig.scott@crascit.com>2020-06-27 08:36:16 (GMT)
committerCraig Scott <craig.scott@crascit.com>2020-06-27 08:38:28 (GMT)
commit95159b7dea20c65e3c1d9b112cd4c5f4646b6a97 (patch)
treeead3bf8fa2d87b397d1b38bd53e57ee113588105 /Tests/RunCMake
parentbc45bdc8193145fcd509a4da9b4095278a6a81ba (diff)
downloadCMake-95159b7dea20c65e3c1d9b112cd4c5f4646b6a97.zip
CMake-95159b7dea20c65e3c1d9b112cd4c5f4646b6a97.tar.gz
CMake-95159b7dea20c65e3c1d9b112cd4c5f4646b6a97.tar.bz2
file(ARCHIVE_CREATE): Rename TYPE option to COMPRESSION
Fixes: #20883
Diffstat (limited to 'Tests/RunCMake')
-rw-r--r--Tests/RunCMake/File_Archive/7zip-with-bad-compression-result.txt (renamed from Tests/RunCMake/File_Archive/zip-with-bad-type-result.txt)0
-rw-r--r--Tests/RunCMake/File_Archive/7zip-with-bad-compression-stderr.txt5
-rw-r--r--Tests/RunCMake/File_Archive/7zip-with-bad-compression.cmake6
-rw-r--r--Tests/RunCMake/File_Archive/7zip.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/RunCMakeTest.cmake3
-rw-r--r--Tests/RunCMake/File_Archive/gnutar-gz.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/gnutar.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/pax-xz.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/pax-zstd.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/pax.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/paxr-bz2.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/paxr.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/roundtrip.cmake6
-rw-r--r--Tests/RunCMake/File_Archive/unsupported-format.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/zip-filtered.cmake2
-rw-r--r--Tests/RunCMake/File_Archive/zip-with-bad-compression-result.txt1
-rw-r--r--Tests/RunCMake/File_Archive/zip-with-bad-compression-stderr.txt (renamed from Tests/RunCMake/File_Archive/zip-with-bad-type-stderr.txt)4
-rw-r--r--Tests/RunCMake/File_Archive/zip-with-bad-compression.cmake (renamed from Tests/RunCMake/File_Archive/zip-with-bad-type.cmake)2
-rw-r--r--Tests/RunCMake/File_Archive/zip.cmake2
19 files changed, 31 insertions, 18 deletions
diff --git a/Tests/RunCMake/File_Archive/zip-with-bad-type-result.txt b/Tests/RunCMake/File_Archive/7zip-with-bad-compression-result.txt
index d00491f..d00491f 100644
--- a/Tests/RunCMake/File_Archive/zip-with-bad-type-result.txt
+++ b/Tests/RunCMake/File_Archive/7zip-with-bad-compression-result.txt
diff --git a/Tests/RunCMake/File_Archive/7zip-with-bad-compression-stderr.txt b/Tests/RunCMake/File_Archive/7zip-with-bad-compression-stderr.txt
new file mode 100644
index 0000000..f6bd1ab
--- /dev/null
+++ b/Tests/RunCMake/File_Archive/7zip-with-bad-compression-stderr.txt
@@ -0,0 +1,5 @@
+CMake Error at roundtrip.cmake:38 \(file\):
+ file archive format 7zip does not support COMPRESSION arguments
+Call Stack \(most recent call first\):
+ 7zip-with-bad-compression.cmake:6 \(include\)
+ CMakeLists.txt:3 \(include\)
diff --git a/Tests/RunCMake/File_Archive/7zip-with-bad-compression.cmake b/Tests/RunCMake/File_Archive/7zip-with-bad-compression.cmake
new file mode 100644
index 0000000..7461eb8
--- /dev/null
+++ b/Tests/RunCMake/File_Archive/7zip-with-bad-compression.cmake
@@ -0,0 +1,6 @@
+set(OUTPUT_NAME "test.zip")
+
+set(ARCHIVE_FORMAT 7zip)
+set(COMPRESSION_TYPE XZ)
+
+include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/7zip.cmake b/Tests/RunCMake/File_Archive/7zip.cmake
index 7b0b9b7..530e940 100644
--- a/Tests/RunCMake/File_Archive/7zip.cmake
+++ b/Tests/RunCMake/File_Archive/7zip.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.7z")
-set(COMPRESSION_FORMAT 7zip)
+set(ARCHIVE_FORMAT 7zip)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/RunCMakeTest.cmake b/Tests/RunCMake/File_Archive/RunCMakeTest.cmake
index 871cb6d..2bd0cd8 100644
--- a/Tests/RunCMake/File_Archive/RunCMakeTest.cmake
+++ b/Tests/RunCMake/File_Archive/RunCMakeTest.cmake
@@ -14,4 +14,5 @@ run_cmake(zip)
run_cmake(zip-filtered)
run_cmake(unsupported-format)
-run_cmake(zip-with-bad-type)
+run_cmake(zip-with-bad-compression)
+run_cmake(7zip-with-bad-compression)
diff --git a/Tests/RunCMake/File_Archive/gnutar-gz.cmake b/Tests/RunCMake/File_Archive/gnutar-gz.cmake
index f4e3975..829022b 100644
--- a/Tests/RunCMake/File_Archive/gnutar-gz.cmake
+++ b/Tests/RunCMake/File_Archive/gnutar-gz.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.tar.gz")
-set(COMPRESSION_FORMAT gnutar)
+set(ARCHIVE_FORMAT gnutar)
set(COMPRESSION_TYPE GZip)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/gnutar.cmake b/Tests/RunCMake/File_Archive/gnutar.cmake
index e5cbd35..17425c7 100644
--- a/Tests/RunCMake/File_Archive/gnutar.cmake
+++ b/Tests/RunCMake/File_Archive/gnutar.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.tar")
-set(COMPRESSION_FORMAT gnutar)
+set(ARCHIVE_FORMAT gnutar)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/pax-xz.cmake b/Tests/RunCMake/File_Archive/pax-xz.cmake
index 47fb0fd..ae485fd 100644
--- a/Tests/RunCMake/File_Archive/pax-xz.cmake
+++ b/Tests/RunCMake/File_Archive/pax-xz.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.tar.xz")
-set(COMPRESSION_FORMAT pax)
+set(ARCHIVE_FORMAT pax)
set(COMPRESSION_TYPE XZ)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/pax-zstd.cmake b/Tests/RunCMake/File_Archive/pax-zstd.cmake
index 59e0443..ba3036e 100644
--- a/Tests/RunCMake/File_Archive/pax-zstd.cmake
+++ b/Tests/RunCMake/File_Archive/pax-zstd.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.tar.zstd")
-set(COMPRESSION_FORMAT pax)
+set(ARCHIVE_FORMAT pax)
set(COMPRESSION_TYPE Zstd)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/pax.cmake b/Tests/RunCMake/File_Archive/pax.cmake
index e50c74f..46002fb 100644
--- a/Tests/RunCMake/File_Archive/pax.cmake
+++ b/Tests/RunCMake/File_Archive/pax.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.tar")
-set(COMPRESSION_FORMAT pax)
+set(ARCHIVE_FORMAT pax)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/paxr-bz2.cmake b/Tests/RunCMake/File_Archive/paxr-bz2.cmake
index 469a131..d38f8f3 100644
--- a/Tests/RunCMake/File_Archive/paxr-bz2.cmake
+++ b/Tests/RunCMake/File_Archive/paxr-bz2.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.tar.bz2")
-set(COMPRESSION_FORMAT paxr)
+set(ARCHIVE_FORMAT paxr)
set(COMPRESSION_TYPE BZip2)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/paxr.cmake b/Tests/RunCMake/File_Archive/paxr.cmake
index e3a4d5c..ce44f05 100644
--- a/Tests/RunCMake/File_Archive/paxr.cmake
+++ b/Tests/RunCMake/File_Archive/paxr.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.tar")
-set(COMPRESSION_FORMAT paxr)
+set(ARCHIVE_FORMAT paxr)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/roundtrip.cmake b/Tests/RunCMake/File_Archive/roundtrip.cmake
index 9050400..f1b0de5 100644
--- a/Tests/RunCMake/File_Archive/roundtrip.cmake
+++ b/Tests/RunCMake/File_Archive/roundtrip.cmake
@@ -1,4 +1,4 @@
-foreach(parameter OUTPUT_NAME COMPRESSION_FORMAT)
+foreach(parameter OUTPUT_NAME ARCHIVE_FORMAT)
if(NOT DEFINED ${parameter})
message(FATAL_ERROR "missing required parameter ${parameter}")
endif()
@@ -37,8 +37,8 @@ file(MAKE_DIRECTORY ${FULL_DECOMPRESS_DIR})
file(ARCHIVE_CREATE
OUTPUT ${FULL_OUTPUT_NAME}
- FORMAT "${COMPRESSION_FORMAT}"
- TYPE "${COMPRESSION_TYPE}"
+ FORMAT "${ARCHIVE_FORMAT}"
+ COMPRESSION "${COMPRESSION_TYPE}"
VERBOSE
DIRECTORY ${COMPRESS_DIR})
diff --git a/Tests/RunCMake/File_Archive/unsupported-format.cmake b/Tests/RunCMake/File_Archive/unsupported-format.cmake
index 61edc1b..4b41e65 100644
--- a/Tests/RunCMake/File_Archive/unsupported-format.cmake
+++ b/Tests/RunCMake/File_Archive/unsupported-format.cmake
@@ -1,5 +1,5 @@
set(OUTPUT_NAME "test.rar")
-set(COMPRESSION_FORMAT rar)
+set(ARCHIVE_FORMAT rar)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/zip-filtered.cmake b/Tests/RunCMake/File_Archive/zip-filtered.cmake
index 2d259bc..e6bdcce 100644
--- a/Tests/RunCMake/File_Archive/zip-filtered.cmake
+++ b/Tests/RunCMake/File_Archive/zip-filtered.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.zip")
-set(COMPRESSION_FORMAT zip)
+set(ARCHIVE_FORMAT zip)
set(DECOMPRESSION_OPTIONS
FILES
diff --git a/Tests/RunCMake/File_Archive/zip-with-bad-compression-result.txt b/Tests/RunCMake/File_Archive/zip-with-bad-compression-result.txt
new file mode 100644
index 0000000..d00491f
--- /dev/null
+++ b/Tests/RunCMake/File_Archive/zip-with-bad-compression-result.txt
@@ -0,0 +1 @@
+1
diff --git a/Tests/RunCMake/File_Archive/zip-with-bad-type-stderr.txt b/Tests/RunCMake/File_Archive/zip-with-bad-compression-stderr.txt
index fe12feb..72ad8c4 100644
--- a/Tests/RunCMake/File_Archive/zip-with-bad-type-stderr.txt
+++ b/Tests/RunCMake/File_Archive/zip-with-bad-compression-stderr.txt
@@ -1,5 +1,5 @@
CMake Error at roundtrip.cmake:38 \(file\):
- file archive format zip does not support TYPE arguments
+ file archive format zip does not support COMPRESSION arguments
Call Stack \(most recent call first\):
- zip-with-bad-type.cmake:6 \(include\)
+ zip-with-bad-compression.cmake:6 \(include\)
CMakeLists.txt:3 \(include\)
diff --git a/Tests/RunCMake/File_Archive/zip-with-bad-type.cmake b/Tests/RunCMake/File_Archive/zip-with-bad-compression.cmake
index ebb97a3..2badd5b 100644
--- a/Tests/RunCMake/File_Archive/zip-with-bad-type.cmake
+++ b/Tests/RunCMake/File_Archive/zip-with-bad-compression.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.zip")
-set(COMPRESSION_FORMAT zip)
+set(ARCHIVE_FORMAT zip)
set(COMPRESSION_TYPE BZip2)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)
diff --git a/Tests/RunCMake/File_Archive/zip.cmake b/Tests/RunCMake/File_Archive/zip.cmake
index 1b93058..09e84b0 100644
--- a/Tests/RunCMake/File_Archive/zip.cmake
+++ b/Tests/RunCMake/File_Archive/zip.cmake
@@ -1,6 +1,6 @@
set(OUTPUT_NAME "test.zip")
-set(COMPRESSION_FORMAT zip)
+set(ARCHIVE_FORMAT zip)
include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)