summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CommandLineTar/set-mtime.cmake
blob: 333cc88fd753fc309898862700d6733b8a020cb8 (plain)
1
2
3
4
5
6
7
8
9
10
11
include(${CMAKE_CURRENT_LIST_DIR}/mtime-tests.cmake)

include(${CMAKE_CURRENT_LIST_DIR}/roundtrip.cmake)

foreach(file ${CHECK_FILES})
  file(TIMESTAMP ${FULL_DECOMPRESS_DIR}/${COMPRESS_DIR}/${file} MTIME UTC)
  if(NOT MTIME STREQUAL ARCHIVE_MTIME_RFC3339)
    message(FATAL_ERROR
      "Extracted timestamp ${MTIME} does not match expected ${ARCHIVE_MTIME_RFC3339}")
  endif()
endforeach()