Skip to content

Rely on `git ls-files` and `git diff` for checking mocks

What does this MR do?

This commit changes the check_mocks behaviour so that it guarantees that the existing commit matches the regenerated mocks. It also compares against the branch HEAD, in case some mock file is missing.

Why was this MR needed?

The existing check_mocks target isn't helpful in determining why a diff happens on the server and not on the client. It only compares the names of changed files instead of the actual contents.

Closes gitlab-org/gitlab-runner#25188 (closed)

Merge request reports