diff --git a/fix_test.patch b/fix_test.patch new file mode 100644 index 0000000..e5781b4 --- /dev/null +++ b/fix_test.patch @@ -0,0 +1,15 @@ +--- test.bash.orig 2019-03-17 16:59:11.000000000 +0100 ++++ test.bash 2019-07-17 16:16:22.184061887 +0200 +@@ -37,10 +37,10 @@ + # Clean up dangling filesystems and don't exit if we found some + unmount_leftovers || true + +-./build-without-openssl.bash ++#./build-without-openssl.bash + # Don't build with openssl if we were passed "-tags without_openssl" + if [[ "$@" != *without_openssl* ]] ; then +- ./build.bash ++ #./build.bash + fi + + if ! go tool | grep vet > /dev/null ; then diff --git a/golang-github-rfjakob-gocryptfs.spec b/golang-github-rfjakob-gocryptfs.spec index 9165270..414b56a 100644 --- a/golang-github-rfjakob-gocryptfs.spec +++ b/golang-github-rfjakob-gocryptfs.spec @@ -15,6 +15,7 @@ Encrypted overlay filesystem written in Go.} %global golicenses LICENSE %global godocs README.md + Name: %{goname} Release: 1%{?dist} Summary: Encrypted overlay filesystem written in Go @@ -22,6 +23,8 @@ Summary: Encrypted overlay filesystem written in Go License: MIT URL: %{gourl} Source0: https://%{goipath}/releases/download/v%{version}/gocryptfs_v%{version}_src.tar.gz +# Patch tests to not rebuild - useful for CI +Patch0: fix_test.patch BuildRequires: golang(github.com/hanwen/go-fuse/fuse) BuildRequires: golang(github.com/hanwen/go-fuse/fuse/nodefs) @@ -34,7 +37,6 @@ BuildRequires: golang(golang.org/x/crypto/ssh/terminal) BuildRequires: golang(golang.org/x/sync/syncmap) BuildRequires: golang(golang.org/x/sys/unix) BuildRequires: openssl-devel -Requires: fuse %description %{common_description} @@ -43,6 +45,7 @@ Requires: fuse %package -n gocryptfs Summary: %{summary} +Requires: fuse %description -n gocryptfs %{common_description} @@ -57,6 +60,7 @@ This package contains the xray tool. %prep %goprep +%patch0 -p0 %build USVERSION=$(cat VERSION) diff --git a/tests/tests.yml b/tests/tests.yml new file mode 100644 index 0000000..e845288 --- /dev/null +++ b/tests/tests.yml @@ -0,0 +1,12 @@ +--- +- hosts: localhost + roles: + - role: standard-test-source + tags: + - classic + + - role: standard-test-basic + tests: + - smoke: + dir: ./source/ + run: ./test.bash