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

[Testing] Migrate functional tests and remove selenium #2491

Open
1 of 7 tasks
ashwin-pc opened this issue Oct 4, 2022 · 2 comments
Open
1 of 7 tasks

[Testing] Migrate functional tests and remove selenium #2491

ashwin-pc opened this issue Oct 4, 2022 · 2 comments
Assignees
Labels
low priority technical debt If not paid, jeapardizes long-term success and maintainability of the repository. test:functional

Comments

@ashwin-pc
Copy link
Member

ashwin-pc commented Oct 4, 2022

Introduction

The testing ecosystem in OpenSearch Dashboards uses Selenium and an installation of Chrome, along with Jest’s Jasmin2. As of June 2021, OpenSearch Dashboards has around 700 functional tests developed in Jest and Selenium. Testing with Selenium is notorious for being flaky and we have had to patch Jasmin2 and other Jest components to partially fight this flakiness. Additionally tests take a long time to run and modern choices are shown to be 25% faster; that sums up to 1.5 hours faster tests.

The official functional testing repository for OpenSearch dashboards is now opensearch-dashboards-functional-test. We need to migrate all our existing Selenium based function tests to the new repository.

Pros of shifting from Selenium to Cypress:

  • Faster test execution due to its architecture
  • Automatic waiting for elements and assertions, reducing flakiness
  • Real-time reloading and time-travel debugging for easier test development
  • Simpler and more intuitive API
  • Better support for modern JavaScript frameworks
  • No need for a separate WebDriver process

Cons of shifting from Selenium to Cypress:

  • Only supports JavaScript, whereas Selenium supports multiple languages
  • Limited to testing on Chromium-based browsers
  • No native support for multi-tab or multi-window testing

Tasks

Tasks are break down to three major parts, research, proposal and implementation.

Research

Proposal

Implementation

@seanneumann
Copy link
Contributor

We need to understand how much work is here and then where to prioritize it.

@ananzh ananzh changed the title [Testing] Migrate functional tests [Testing] Migrate functional tests and remove selenium Mar 23, 2023
@ananzh ananzh self-assigned this Mar 24, 2023
@ananzh ananzh added the OSCI Open Source Contributor Initiative label Mar 27, 2023
@ashwin-pc ashwin-pc removed the OSCI Open Source Contributor Initiative label Mar 29, 2023
@kavilla
Copy link
Member

kavilla commented Apr 5, 2024

Reducing priority as we will complete this as we go. Migrating tests whenever we are doing updates to that part of the repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
low priority technical debt If not paid, jeapardizes long-term success and maintainability of the repository. test:functional
Projects
None yet
Development

No branches or pull requests

5 participants