-
Notifications
You must be signed in to change notification settings - Fork 180
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
(TFECO-8323) Port UI tests to vscode-extension-tester and remove wdio #1873
Conversation
5533551
to
6bc8e54
Compare
04c7403
to
3a4abcb
Compare
553b9e2
to
a313c46
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work! This looks much better than the previous wdio setup.
I left a couple of questions
a313c46
to
608d49c
Compare
608d49c
to
b92ec55
Compare
d3d22c9
to
bd30f6a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work!
Closes #1716
This installs the redhat extension tester and removes the wdio test runner and its dependencies from the project. This allows us to test treeviews, which is what the HCP integration uses, locally and in CI in a reliable manner. This is large port of existing UI tests to a new API and it required a new way to run the tests. So a script that runs the tests has been created that will run the tests in a headless mode when running in CI and in a windowed mode when running locally. This is to ensure that the tests can be run in a reliable manner in both environments. It also mocks the HCP API so that the tests can be run without needing to have a connection to HCP infrastructure. A bug in the login workflow was found during this effort. After successfully authenticing, the organization picker was left open and could not be closed. This was fixed by disposing the organization picker after successfully authenticating. Since the primary focus was on the HCP treeview tests (most likely to break when changing this area), the Terraform treeview tests (which have much simpler functionality) were not updated and left for a future PR. This also fixes the issue with the `test.yml` file where the `VSCODE_VERSION` was not being set correctly. This was causing the tests to not actually run with different versions of VSCode. A minor addition to the eslint ruleset to allow for the use of `unsafe` access or `any` in the codebase where it is needed, specifically in places where we interact with libraries that are not typed or where we need to access properties that are not typed.
f7d6eba
to
3a36587
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
This installs the redhat extension tester and removes the wdio test runner and its dependencies from the project. This allows us to test treeviews, which is what the HCP integration uses, locally and in CI in a reliable manner.
This is large port of existing UI tests to a new API and it required a new way to run the tests. So a script that runs the tests has been created that will run the tests in a headless mode when running in CI and in a windowed mode when running locally. This is to ensure that the tests can be run in a reliable manner in both environments. It also mocks the HCP API so that the tests can be run without needing to have a connection to HCP infrastructure.
A bug in the login workflow was found during this effort. After successfully authenticing, the organization picker was left open and could not be closed. This was fixed by disposing the organization picker after successfully authenticating.
Since the primary focus was on the HCP treeview tests (most likely to break when changing this area), the Terraform treeview tests (which have much simpler functionality) were not updated and left for a future PR.
This also fixes the issue with the
test.yml
file where theVSCODE_VERSION
was not being set correctly. This was causing the tests to not actually run with different versions of VSCode.A minor addition to the eslint ruleset to allow for the use of
unsafe
access orany
in the codebase where it is needed, specifically in places where we interact with libraries that are not typed or where we need to access properties that are not typed.