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

Add basic MSI tests to CI #753

Merged
merged 25 commits into from
Dec 18, 2024
Merged

Conversation

pjanotti
Copy link
Contributor

@pjanotti pjanotti commented Nov 26, 2024

Resolve #576 by adding smoke tests to the MSI package created for Windows. This follow the pattern as the package-tests written for deb and rpm packages. The tests are limited to amd64 since this is the most common target for Windows and the MSI code itself doesn't differ per CPU architecture.

The tests themselves are written in go to facilitate future additions to the tests, e.g.: upgrade scenarios. I opted to add dedicated go.mod and go.sum to not mix the test dependencies with the ones on the repository root.

@pjanotti pjanotti changed the title Add github workflow for MSI tests Add basic MSI tests to CI Dec 5, 2024
@pjanotti pjanotti marked this pull request as ready for review December 5, 2024 21:34
@pjanotti pjanotti requested a review from a team as a code owner December 5, 2024 21:34
Copy link
Member

@andrzej-stencel andrzej-stencel left a comment

Choose a reason for hiding this comment

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

I can see the test running and passing on this PR https://github.com/open-telemetry/opentelemetry-collector-releases/actions/runs/12261110160/job/34207631963?pr=753 👍

I'd love to see a Makefile target, so that I can easily run these tests on my local machine or in any other environment. This would help in reproducibility of the test.

Also (or maybe instead of the Makefile target) documentation describing the prerequisites, like building the MSI package first.

@pjanotti
Copy link
Contributor Author

@andrzej-stencel the challenge here is that to build the MSI locally I think one needs to have a goreleaser key to the pro version. I think a Powershell script that sets up the environment variables required by the test could be a good follow-up. So instead of setting up those on the CI job we use the script to do that instead and same script can be used locally with any MSI that the user wants.

Copy link
Member

@mowies mowies left a comment

Choose a reason for hiding this comment

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

Pipelines LGTM

If you want to fix the broken package tests, you can follow what I my commented here.

.github/workflows/base-ci-goreleaser.yaml Outdated Show resolved Hide resolved
pjanotti and others added 2 commits December 18, 2024 08:29
Co-authored-by: Moritz Wiesinger <moritz.wiesinger@dynatrace.com>
@djaglowski djaglowski added this pull request to the merge queue Dec 18, 2024
Merged via the queue into open-telemetry:main with commit 917aa99 Dec 18, 2024
51 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add MSI smoke tests
5 participants