Reference Application 2.13.0-SNAPSHOT Testing

Well done :clap:@jwnasambu, Just a quick question can these tests be done via QA framework or have to be done manually.

Regards,

Am going to do both manual and automated testing. Kindly feel free to do what is convinient with you. The manual testing will be limited to features whose test cases don’t exist on the QA framwork.

@mherman22 do you have the bandwidth to backUp the release manager in setting up the environment for the automated tests to run on RefApp 2.13.0-SNAPSHOT? @jwnasambu do we have the UAT server setup already?

Yeah i do, and i think this should be as easy as changing the qa-refapp server to use this released version of refapp. Then, we will trigger the workflows using github actions.

If the interest is in setting up the environment locally, i will be available to assist

Kindly @mherman22 and @kdaud how can I get access to the QA repository so that I can be able to trigger the workflows?

Please look through → OpenMRS Platform 2.6.0-beta (Ready for Testing) - #11 by mherman22 to be able to do the local setup.

For triggering the workflows using github actions, look through → OpenMRS Platform 2.6.0-beta (Ready for Testing) - #13 by kdaud as an alternative as we wait for @kdaud

1 Like

@jwnasambu is the server for RefApp 2.13.0-SNAPSHORT(something like UAT server) already set up?

Oh sorry! you didn’t get the chance to see it. This is the UAT server link Login. Besides, am trying to come up with a write up to guide members interested in testing in relation to what my mentor @mherman22 has shared.

1 Like

@jwnasambu could you raise a PR to switch the server at test-local.property files 1–> and <—2 to point at the UAT instance?

Keeping in mind that the qa-server is already having the same configurations as can be seen at openmrs-distro-referenceapplication/pom.xml at 4a083070d1f1f6543fed74a0a4f33dbfe4a68dd4 · openmrs/openmrs-distro-referenceapplication · GitHub

@kdaud I have raised the PR on this link Switch server by jwnasambu · Pull Request #478 · openmrs/openmrs-contrib-qaframework · GitHub. However, all the tests are failing after switching to the UAT server because of Unable to locate element: *[name='OWASP-CSRFTOKEN'](..).

I have put a comment on the PR.

Are you interested in running automated tests for Reference Application 2.13.0-SNAPSHOT locally? Kindly follow these steps:

  1. clone the repository → GitHub - openmrs/openmrs-contrib-qaframework.

  2. cd into the repository using → cd openmrs-contrib-qaframework

  3. Import the project in your preferred IDE and change the test.properties file to something like this:

webapp.url=https://uat-refapp.openmrs.org/openmrs                                                                                        
login.username=admin
login.password=Admin123
login.location=Pharmacy
webdriver=chrome
headless=false
webdriver.gecko.driver=chromedriver/mac/chromedriver
includes.csrftoken=false

and save the changes.

  1. Navigate to the qaframework-bdd-tests module using → cd qaframework-bdd-tests.
  2. Trigger npm run in the terminal in order to see all the workflows that have been created
  3. Trigger any test workflow by running the command: → npm run workflowName, e.g. npm run refapp2ClinicalVisit

Kindly report you findings on this link.

Are you interested in running automated tests for Reference Application 2.13.0-SNAPSHOT locally? Kindly follow these steps:

  1. clone the repository → GitHub - openmrs/openmrs-contrib-qaframework.

  2. cd into the repository using → cd openmrs-contrib-qaframework

  3. Import the project in your preferred IDE and change the test.properties file to something like this:

webapp.url=https://uat-refapp.openmrs.org/openmrs                                                                                        
login.username=admin
login.password=Admin123
login.location=Pharmacy
webdriver=chrome
headless=false
webdriver.gecko.driver=chromedriver/mac/chromedriver
includes.csrftoken=false

and save the changes.

  1. Navigate to the qaframework-bdd-tests module using → cd qaframework-bdd-tests.
  2. Trigger npm run in the terminal in order to see all the workflows that have been created
  3. Trigger any test workflow by running the command: → npm run workflowName, e.g. npm run refapp2ClinicalVisit

Kindly report you findings on this link Reference Application 2.13.0-SNAPSHOT Testing - Google Sheets

cc@jayasanka, @piumal1999, @MekomSolutions, @PIH, @mherman22 , @ugandaemr, @kdaud, @AMPATH, @tendomart, @devnull, @dev1, @dev2, @dev3, @dev4, @dev5

2 Likes

Hello friends, I know testing this release has not been a walk in the park but nevertheless, I want to say thank you for the spirit and patience. Since the tests were flopping on the github action, we opted to run automated tests locally in the feature file linked to every workflow and spinned the tests against the https://uat-refapp.openmrs.org/openmrs/ which is running Reference Application 2.13.0-SNAPSHOT and this is our findings. As communicated prior we anticipate the release to come-out anytime from now not unless we face any constrain beyond our control. Thanks!

It’s a bit strange to see only 25% of the automated tests passing in github actions when running with the uat server for RefApp 2.13.0-SNAPSHOT. The rest of the tests are throwing a general server failure(HTTP 404 not found), I am not able to figure out the real cause of the issue but this could be something worth considering before releasing the refapp.

@ibacher @dkayiwa what could be your advise?

@kdaud are you able to reproduce any of those errors, on uat-refapp, when you manually do what the tests are automating?

The manual attempt could not reproduce any of those errors. Taking further investigation on github actions have been able to figure out the reason why the tests were failing before and made commits (a8cd9eb, a6665d8) that made the tests pass. Though there remains only two tests failing which am investigating but I realize enabling the includes.csrftoken functionality makes all the tests fail login step probably because the functionality was introduced in platform 2.6.0 and the uat is using 2.5.9.

Unable to locate element: *[name='OWASP-CSRFTOKEN']

I may not tell why we are not using the recent released platform version, @jwnasambu could you help me understand the pitfall that were occurring when using the new version which led to this downgrade?

FYI, the qa-refapp server is also running on 2.5.9 as can be seen at https://qa-refapp.openmrs.org/openmrs/ws/rest/v1/systeminformation and the tests seem to be passing on the qa-refapp server.

@dkayiwa we now have all the tests passing in github actions running against uat server when includes.csrftoken is disabled otherwise they all fail with the error I shared above. Is it worth looking for the workaround to have the tests pass when the property is enabled or @jwnasambu can proceed with releasing the refapp 2.13.0?