Add indications in the tests

This commit is contained in:
Alejandro Sáez 2023-11-09 12:15:49 +01:00
parent 335d81de5f
commit 21dcfead0c

View File

@ -497,7 +497,6 @@ sed -i 's/const defaultGO_LDSO = `.*`/const defaultGO_LDSO = ``/' $RPM_BUILD_ROO
%endif
%check
echo ">>> check <<<"
export GOROOT=$(pwd -P)
export PATH="$GOROOT"/bin:"$PATH"
cd src
@ -529,22 +528,25 @@ export GO_TEST_RUN=""
export GO_TEST_RUN="-run=!testshared"
%endif
echo "=== Start testing ==="
%if %{fail_on_tests}
./run.bash --no-rebuild -v -v -v -k $GO_TEST_RUN
%if %{fips}
echo "=== Running FIPS tests ==="
# tested25519vectors needs network connectivity but it should be cover by
# this test https://pkgs.devel.redhat.com/cgit/tests/golang/tree/regression/internal-testsuite/runtest.sh#n127
# run tests with fips enabled.
export GOLANG_FIPS=1
export OPENSSL_FORCE_FIPS_MODE=1
echo "=== Run all crypto test skipping tls ==="
pushd crypto
# run all crypto tests but skip tls, we will run fips specific tls tests later
go test $(go list ./... | grep -v tls) -v
# check that signature functions have parity between boring and notboring
CGO_ENABLED=0 go test $(go list ./... | grep -v tls) -v
popd
echo "=== Run tls tests ==="
# run all fips specific tls tests
pushd crypto/tls
go test -v -run "Boring"
@ -553,6 +555,7 @@ export GO_TEST_RUN=""
%else
./run.bash --no-rebuild -v -v -v -k || :
%endif
echo "=== End testing ==="
cd ..
%post bin