vektra / mockery

A mock code autogenerator for Go
https://vektra.github.io/mockery/
BSD 3-Clause "New" or "Revised" License
5.8k stars 395 forks source link

Dockerfile: up go version to 1.22 #755

Closed ifross89 closed 4 months ago

ifross89 commented 4 months ago

Description

Currently using mockery via docker does not work on projects using go 1.22.

An example of the error is:

err: exit status 1: stderr: go: go.mod requires go >= 1.22 (running go 1.21.7; GOTOOLCHAIN=local)

09 Feb 24 10:19 UTC ERR unable to parse packages error="err: exit status 1: stderr: go: go.mod requires go >= 1.22 (running go 1.21.7; GOTOOLCHAIN=local)\n" dry-run=false version=v2.40.2

This happens because the go version in the Dockerfile is go 1.21.

This change upgrades the go version in the Dockerfile to use go 1.22, allowing the

Type of change

Version of Golang used when building/testing:

How Has This Been Tested?

I have built and run the docker locally

Checklist