Blame SOURCES/openscap-1.3.7-PR-1844-fix-test-ds-misc-2.patch

09cc0a
From 650656bdac5e8e4df30c11bb4dbc830aab8baa78 Mon Sep 17 00:00:00 2001
09cc0a
From: =?UTF-8?q?Jan=20=C4=8Cern=C3=BD?= <jcerny@redhat.com>
09cc0a
Date: Tue, 1 Feb 2022 15:06:33 +0100
09cc0a
Subject: [PATCH] Prevent fails of test_ds_misc.sh
09cc0a
09cc0a
Other files from which the datastream is composed might also
09cc0a
affect the timestamp attributes in result document depending
09cc0a
on their mtime.
09cc0a
---
09cc0a
 tests/DS/test_ds_misc.sh | 4 +++-
09cc0a
 1 file changed, 3 insertions(+), 1 deletion(-)
09cc0a
09cc0a
diff --git a/tests/DS/test_ds_misc.sh b/tests/DS/test_ds_misc.sh
09cc0a
index cffbef303..1777c44f4 100755
09cc0a
--- a/tests/DS/test_ds_misc.sh
09cc0a
+++ b/tests/DS/test_ds_misc.sh
09cc0a
@@ -270,7 +270,9 @@ function test_source_date_epoch() {
09cc0a
 	export SOURCE_DATE_EPOCH="1583410177"
09cc0a
 	export TZ=UTC
09cc0a
 	# ensure the file mtime is always newer than the $timestamp
09cc0a
-	touch -c "$xccdf"
09cc0a
+	touch -c "$srcdir/sds_multiple_oval/first-oval.xml"
09cc0a
+	touch -c "$srcdir/sds_multiple_oval/multiple-oval-xccdf.xml"
09cc0a
+	touch -c "$srcdir/sds_multiple_oval/second-oval.xml"
09cc0a
 	$OSCAP ds sds-compose "$xccdf" "$result"
09cc0a
 	assert_exists 3 '//ds:component[@timestamp="'$timestamp'"]'
09cc0a
 	rm -f "$result"