aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-08-19 00:53:58 +0200
committerGitHub <noreply@github.com>2020-08-19 00:53:58 +0200
commit9d096c1c4ea5308c94f779444b61015eeef2972a (patch)
tree5ab878b518459f821e4c73d4e35f10c26569d5bd
parentff1f81b14a2944a1651e1b404681972ff3483d36 (diff)
parentd9f0c48176cb5049605ae0e3aad4173685d9c6ea (diff)
downloadpodman-9d096c1c4ea5308c94f779444b61015eeef2972a.tar.gz
podman-9d096c1c4ea5308c94f779444b61015eeef2972a.tar.bz2
podman-9d096c1c4ea5308c94f779444b61015eeef2972a.zip
Merge pull request #7361 from Luap99/version-builttime
fix podman version output to include git commit and builttime
-rw-r--r--Makefile2
-rw-r--r--test/system/001-basic.bats7
2 files changed, 8 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 4c9440fc5..8ce1946ee 100644
--- a/Makefile
+++ b/Makefile
@@ -62,7 +62,7 @@ else
BUILD_INFO ?= $(shell date "+$(DATE_FMT)")
ISODATE ?= $(shell date --iso-8601)
endif
-LIBPOD := ${PROJECT}/libpod
+LIBPOD := ${PROJECT}/v2/libpod
GCFLAGS ?= all=-trimpath=${PWD}
ASMFLAGS ?= all=-trimpath=${PWD}
LDFLAGS_PODMAN ?= \
diff --git a/test/system/001-basic.bats b/test/system/001-basic.bats
index b23107e79..a5a3324fb 100644
--- a/test/system/001-basic.bats
+++ b/test/system/001-basic.bats
@@ -24,6 +24,13 @@ function setup() {
is "${lines[0]}" "Version:[ ]\+[1-9][0-9.]\+" "Version line 1"
is "$output" ".*Go Version: \+" "'Go Version' in output"
is "$output" ".*API Version: \+" "API version in output"
+
+ # Test that build date is reasonable, e.g. after 2019-01-01
+ local built=$(expr "$output" : ".*Built: \+\(.*\)" | head -n1)
+ local built_t=$(date --date="$built" +%s)
+ if [ $built_t -lt 1546300800 ]; then
+ die "Preposterous 'Built' time in podman version: '$built'"
+ fi
}