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 K6_BROWSER_EXECUTABLE_PATH in ci #962

Merged
merged 7 commits into from
Aug 17, 2023
Merged

Add K6_BROWSER_EXECUTABLE_PATH in ci #962

merged 7 commits into from
Aug 17, 2023

Conversation

ankur22
Copy link
Collaborator

@ankur22 ankur22 commented Jul 7, 2023

Description of changes

The main change (initially) was to work with the K6_BROWSER_EXECUTABLE_PATH env var on linux github actions to ensure it picks chrome and not chromium. The github runners have both chromium and google chrome installed. Google chrome is kept up to date whereas chromium isn't. We want to work with the latest version of google chrome (for now, in the future we may want to install the exact version we want to work with).

I also found that the e2e workflow wasn't correctly using the defined matrix, and was only working with ubuntu-latest. There are several commits which attempt to resolve this.

Two issues which were discovered but not resolved in the e2e workflow were:

  1. the examples/hosts.js test script doesn't pass in the Windows stable e2e test. When tested in a Windows 11 computer, the test passed. I've opened a new issue (Fix e2e & test CI workflows #963) to track this.
  2. the Windows tip e2e test fails when building a k6 binary with xk6 and the tip version of go. The tip version of go is installed successfully and we seem to be setting it up correctly (ensuring GOROOT is pointing to the tip version and not the stable version that is already on the system), but even still xk6 works with the stable version of go which ends up with an error. This hasn't been tested on a standalone windows computer. I've opened a new issue (Investigate why tip e2e tests on Windows github action runner fails #1002) to track this.

Closes: #963

Checklist

@ankur22 ankur22 marked this pull request as draft July 7, 2023 14:58
@ankur22 ankur22 force-pushed the fix/ci-google-chrome branch 3 times, most recently from 2e13017 to 8ff018c Compare July 7, 2023 15:30
@ankur22 ankur22 force-pushed the fix/ci-google-chrome branch from e65317e to fa7e2a0 Compare August 10, 2023 14:31
The github runners have both chromium and google chrome installed.
Google chrome is kept up to date whereas chromium isn't. We want to
work with the latest version of google chrome (for now, in the future
we may want to install the exact version we want to work with).

We've had issues working with chromium in the runners where the
application crashes on startup.
@ankur22 ankur22 force-pushed the fix/ci-google-chrome branch 4 times, most recently from 0a455ba to f704402 Compare August 16, 2023 15:27
It's not known why this example doesn't work in the github action
runner. It works fine on a Windows 11 computer.
@ankur22 ankur22 force-pushed the fix/ci-google-chrome branch 10 times, most recently from ef03811 to e0bf96e Compare August 16, 2023 22:11
@ankur22 ankur22 requested review from inancgumus and ka3de August 16, 2023 22:14
@ankur22 ankur22 marked this pull request as ready for review August 16, 2023 22:14
ka3de
ka3de previously approved these changes Aug 17, 2023
Copy link
Collaborator

@ka3de ka3de left a comment

Choose a reason for hiding this comment

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

Thanks for looking into this! LGTM.

.github/workflows/e2e.yml Show resolved Hide resolved
.github/workflows/test.yml Show resolved Hide resolved
.github/workflows/e2e.yml Show resolved Hide resolved
inancgumus
inancgumus previously approved these changes Aug 17, 2023
Copy link
Member

@inancgumus inancgumus left a comment

Choose a reason for hiding this comment

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

Thanks for making things better 👍

.github/workflows/e2e.yml Show resolved Hide resolved
@ankur22 ankur22 dismissed stale reviews from inancgumus and ka3de via 2be84e3 August 17, 2023 10:05
@ankur22 ankur22 force-pushed the fix/ci-google-chrome branch from 2be84e3 to e0bf96e Compare August 17, 2023 10:13
ka3de
ka3de previously approved these changes Aug 17, 2023
Copy link
Collaborator

@ka3de ka3de left a comment

Choose a reason for hiding this comment

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

LGTM.

@ankur22 ankur22 force-pushed the fix/ci-google-chrome branch 3 times, most recently from 02bd099 to e0bf96e Compare August 17, 2023 10:46
The e2e workflow for windows using the tip version of go doesn't seem
to work on Windows (or at least in the ci github action). The tip is
installed correctly, but when it comes to building the k6 binary using
xk6, xk6 seems to always execute the stable version of the go binary
and not the tip version. When running commands outside of xk6 to
verify the env vars (e.g. GOROOT) it always returns the tip paths. It's
unclear why this is happening.

For now, we're skipping the windows e2e tip workflow.
@ankur22 ankur22 force-pushed the fix/ci-google-chrome branch from e0bf96e to 7d983cd Compare August 17, 2023 11:12
@ankur22 ankur22 merged commit e7cbc5c into main Aug 17, 2023
@ankur22 ankur22 deleted the fix/ci-google-chrome branch August 17, 2023 11:29
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.

Fix e2e & test CI workflows
3 participants