bujjibabukatta opened a new pull request, #9128:
URL: https://github.com/apache/devlake/pull/9128
Closes: #9088
## Summary
`backend/mocks/` is gitignored but imported by tracked source code
(`helpers/unithelper`) and test files (`helpers/pluginhelper/api`).
On a fresh clone this breaks `go mod tidy`, `go build ./...`, IDE
tooling, and Dependabot's gomod ecosystem.
## Root Cause
The mocks are generated via `mockery` but never committed. Since
`helpers/unithelper` imports them directly (not as test-only code),
Go can't find these packages on a clean checkout and tries to fetch
them as external modules, which fails.
## Fix
- Removed `backend/mocks/` from `.gitignore`.
- Committed the generated mock files (`make mock`, mockery v3.7.4).
No changes to `go.mod`/`go.sum`.
- Added a CI step to run `make mock` and diff against the committed
mocks, so they can't silently go stale.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]