summaryrefslogtreecommitdiffstats
path: root/tests/run.sh
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2024-06-04 12:52:39 -0400
committerTavian Barnes <tavianator@tavianator.com>2024-06-04 12:52:39 -0400
commitc6bb003b8882e9a16941f5803d072ec1cb728318 (patch)
tree273d7b3de70212b75bf6c841c70142a00fec5d3c /tests/run.sh
parent3da7fe8b4f5d6a41152d81bbfbd30b0ab3a9da1c (diff)
downloadbfs-c6bb003b8882e9a16941f5803d072ec1cb728318.tar.xz
xtime: Add support for @epochseconds timestamps
Diffstat (limited to 'tests/run.sh')
-rw-r--r--tests/run.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/run.sh b/tests/run.sh
index 8c1402d..115a036 100644
--- a/tests/run.sh
+++ b/tests/run.sh
@@ -410,6 +410,12 @@ make_xattrs() {
esac
}
+# Get the Unix epoch time in seconds
+epoch_time() {
+ # https://stackoverflow.com/a/12746260/502399
+ awk 'BEGIN { srand(); print srand(); }'
+}
+
## Snapshot testing
# Return value when a difference is detected