Skip to content

T 01 Testing

Esteban edited this page May 21, 2021 · 6 revisions

Testing Machete

UI Tests

Ubuntu 20.04: To run Selenium test, you need to download the appropriate chrome driver:

  1. Find your chrome version
  2. Download the matching chrome driver (based on your chrome version): https://chromedriver.chromium.org/downloads
  3. extract the Zip file and move the chromedriver to /usr/local/bin
  • sudo mv chromedriver /usr/local/bin
  • sudo chown root:root /usr/local/bin
  • sudo chmod +x /usr/local/bin/chromedriver

Local Dev

Selenium tests should run agains a running Machete instance on localhost with the default configuration on Machete/Machete.Selenium/appsettings.json. The configuration is expecting a user selenium.uitest with first name selenium and last name uitest. This users should have the following roles:

Selenium User Roles

  • Administrator
  • Teacher

Remote Test Environment

To test against a deployed test environment, go to Machete/Machete.Selenium/appsettings.json and change the values below. You will need to enter the correct

  • sqlserver
  • db user and db password
  • as well as the db name.

This assumes that you have an open connection to the test environment DB and a Machete user with a user with the roles on the :

  • defaul
  • defaultReadOnly
  • chromeDriverPath -> where the chromedriver is installed
  • baseSeleniumTestUrl -> the url of the deployed test environment
  • seleniumUser -> the machete user for UI Testing. The user should have the roles in the Selenium User Roles section above.
  • seleniumUserPassword -> the machete user Password for UI Testing