Skip to content

feat: add make targets for the Gitlab-backed test loop - #668

Draft
feiyunzhou wants to merge 1 commit into
Roche:mainfrom
feiyunzhou:chore-local-gitlab-e2e-loop
Draft

feiyunzhou wants to merge 1 commit into
Roche:mainfrom
feiyunzhou:chore-local-gitlab-e2e-loop

Conversation

@feiyunzhou

Copy link
Copy Markdown
Contributor

WHY?

Checking a hoster or change-service fix against a real Gitlab currently looks
like a research task. CONTRIBUTING.md sends you to Gitlab's own install docs,
even though this repository already starts a Gitlab instance for its CI in
docker-compose.tests.yml, and the end-to-end tests under tests/e2e/ already
run the foxops app in-process against it. That is the quickest way to cover a
change all the way down to the Gitlab API, and nothing pointed at it.

WHAT?

  • Add gitlab-up, gitlab-down and test-gitlab make targets that start the
    bundled Gitlab and run the suite against it. test-gitlab accepts
    PYTEST_ARGS, so a subset can be iterated on.
  • Rewrite the "Run Tests that Require Gitlab" section around those targets, and
    state that the end-to-end tests reach the Gitlab API without an image build or
    a deployment.
  • Record that gitlab/gitlab-ce is published for amd64 only, and that under
    emulation it reports itself healthy while answering part of the suite with
    502 Bad Gateway.

ADDITIONAL NOTES

FOXOPS_TESTS_GITLAB_USERNAME/_PASSWORD was already supported by the test
settings and is what CI uses, but it was undocumented. The make target uses it so
that the bundled instance needs no access token.
FOXOPS_TESTS_GITLAB_ROOT_GROUP_ID stays optional; without it the temporary
projects land in the authenticated user's namespace.

Ran the end-to-end tests through make test-gitlab against the bundled instance,
and through the environment variables against a remote Gitlab. Both were on an
arm64 host, where the emulation caveat above is what I ran into.

The repository already ships the Gitlab instance that CI tests against, but
CONTRIBUTING.md pointed at Gitlab's own install docs instead and never
mentioned docker-compose.tests.yml. Wire the compose file and the
FOXOPS_TESTS_GITLAB_* variables into make targets so a contributor can run the
end-to-end tests against a real Gitlab in one command, and say in
CONTRIBUTING.md that those tests cover the path down to the Gitlab API without
an image build or a deployment.
@feiyunzhou feiyunzhou changed the title test: add make targets for the Gitlab-backed test loop feat: add make targets for the Gitlab-backed test loop Nov 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant