Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run all unit tests on the main branch in GitHub actions. #2528

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

ptodev
Copy link
Collaborator

@ptodev ptodev commented Jan 24, 2025

A GitHub action which runs make test. The corresponding Drone pipeline can be removed later on.

@dehaansa dehaansa marked this pull request as ready for review January 30, 2025 19:13
@dehaansa dehaansa requested a review from a team as a code owner January 30, 2025 19:13
with:
go-version-file: go.mod
# TODO: Enable caching later.
cache: false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not enable it now?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While I was testing these changes, the runners ran out of disk space. Then I disabled the caching and they worked fine.

Caches tend to be specific to branches and workflows... there are also race conditions if steps within a workflow run concurrently. For example:
actions/setup-go#358
https://github.com/actions/setup-go/pull/416/files

OTel doesn't use the setup-go cache, instead they use the generic caching action. They run it at the start of the workflow and all other workflow steps wait for it to complete before running. This looks like a better approach, but I'd like us to test it first.

For such an essential and widely used feature, it appears really complicated to configure it the right way.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we use it for the integration tests and I think that so far it worked well but maybe it was not a problem because we had less workflow. I'm happy to leave it disabled for now but we should keep it in the radar because 20mins to run the tests is a lot

.drone/drone.yml Outdated Show resolved Hide resolved
.github/workflows/test_full.yml Outdated Show resolved Hide resolved
ptodev and others added 3 commits January 31, 2025 10:32
A GitHub action which runs `make test`. The corresponding Drone pipeline can be removed later on.
@ptodev ptodev force-pushed the ptodev/gh-actions-tests-full branch from 2fa5123 to 1997c99 Compare January 31, 2025 10:32
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.

3 participants