Saving screen recordings of failing RefApp 3.x E2E workflows

The problem:

If a 3.x E2E test fails, the relevant GitHub action will fail with an error message. Most of the time the error messages are too generic (ex: “Couldn’t find element X ”) and hard to get an idea of. To identify the issue, the developers must obtain a clone of the QA framework and run the specific test locally using Cypress Runner. Business-type stakeholders require the assistance of developers to identify the actual problem. Moreover, there might be some rare scenarios that are hard to reproduce locally. Especially, the current setup sometimes throws random errors.

Proposed solution:

Cypress has an inbuilt screen recording feature. So that we could record the screen and attach the recordings of failed tests to the GitHub workflow. With that, anyone can check failing workflow in the QA dashboard and play the attached screen recording without running them locally. It saves a lot of time and effort.

@pasindur2, I would like to assign this task to you because you are interested in contributing. It would be helpful for you to become acquainted with our QA platform. Please do not hesitate to reach out if you have any questions. Let me know a time, let’s have an onboarding session.

@bistenes @christine @grace @kdaud @sharif Let me know your thoughts. :hugs:

Useful resources:

2 Likes

Thank You @jayasanka. I will start working on this task. :slightly_smiling_face:

1 Like

Well done @jayasanka , this is a nice approach of using flowchart, Are you only capturing if a test fails? What would happens if the test pass

1 Like

Thanks, @sharif!

Yes, I’m suggesting attaching only the recordings of failing tests. Passing tests will remain as it is now and marked in green.

These are the assumptions I made:

  • There’s no critical use case to have screen recordings of passing tests because they are always the same.
  • Github has a storage limit for actions.
  • Possibility of test failure is comparatively low.
2 Likes

PR is ready for this task.

Here is the link - RATEST-207: Attach screen recordings of failed 3.x tests to gh-action by pasindur99 · Pull Request #100 · openmr

Hereby, I added a small description about this task.

Purpose

The pull request is to add a new feature of attaching screen recording of failed 3. x tests and this pull request is related to the issue ticket number RATEST-207.

Goals

  • To allow developers/stakeholders to identify why tests failing by playing the screen recording without running them locally.
  • To save time

Approach

  1. Make cypress screen recording facility turn on.
  2. Make 3. x test GitHub workflows to save the test of failed tests.

Screenshots

Passed test

image

Failed test

A failed test - (Link)

image

1 Like

Excellent!! Thanks for getting this done @pasindur2 ! This will help to save a lot of time of our developers! :hugs:

Can you implement the same for the Dictionary Manager? The tests are running in a single workflow file, probably we need to delete videos of passing tests. This might help: Screenshots and Videos | Cypress Documentation

1 Like

Sure @jayasanka I will look into that task also. Thank you for assigned this task for me.

1 Like

For the dictionary manager, we already save screenshots of the failed tests… Those are usually enough and much friendlier to our storage provider.

1 Like

Oh I didn’t aware about it. Shall we do the same for this? instead of saving videos?

No, that’s perfectly fine!

1 Like