Skip to content

Commit

Permalink
Update fuzz dependencies
Browse files Browse the repository at this point in the history
Signed-off-by: Paulo Gomes <[email protected]>
  • Loading branch information
Paulo Gomes committed Apr 19, 2022
1 parent cb2c36c commit 0e7aded
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions tests/fuzz/oss_fuzz_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,6 @@ go get -d github.com/AdaLogics/go-fuzz-headers

pushd "tests/fuzz"

# Version of the source-controller from which to get the GitRepository CRD.
# Change this if you bump the source-controller/api version in go.mod.
SOURCE_VER=v0.22.2

# Version of the image-reflector-controller from which to get the ImagePolicy CRD.
# Change this if you bump the image-reflector-controller/api version in go.mod.
REFLECTOR_VER=v0.17.1

# Setup files to be embedded into controllers_fuzzer.go's testFiles variable.
mkdir -p testdata/crds
cp ../../config/crd/bases/*.yaml testdata/crds/
Expand All @@ -78,6 +70,14 @@ sed -i 's;module .*;module github.com/fluxcd/image-automation-controller/tests/f
sed -i 's;api => ./api;api => ../../api;g' go.mod
echo "replace github.com/fluxcd/image-automation-controller => ../../" >> go.mod

# Version of the source-controller from which to get the GitRepository CRD.
# Pulls source-controller/api's version set in go.mod.
SOURCE_VER=$(go list -m github.com/fluxcd/source-controller/api | awk '{print $2}')

# Version of the image-reflector-controller from which to get the ImagePolicy CRD.
# Pulls image-reflector-controller/api's version set in go.mod.
REFLECTOR_VER=$(go list -m github.com/fluxcd/image-reflector-controller/api | awk '{print $2}')

go mod download

if [ -d "../../controllers/testdata/crds" ]; then
Expand All @@ -90,7 +90,7 @@ else
fi

go get -d github.com/AdaLogics/go-fuzz-headers
go get github.com/fluxcd/image-automation-controller
go get -d github.com/fluxcd/image-automation-controller

# Using compile_go_fuzzer to compile fails when statically linking libgit2 dependencies
# via CFLAGS/CXXFLAGS.
Expand Down

0 comments on commit 0e7aded

Please sign in to comment.