This repository consist of a series of Selenium tests that will be used to automatically validate changes between the shared ProcessMaker and Ellucian architectures.
These tests will ultimately be executed within a PM4 custom instance dubbed "Trogdor". Trogdor processes will be initiated via CI/API and then will execute the tests in this repository against the environment specified in the API call. Once the tests have completed a report of the results will be provided, and in certain cases it will trigger a follow up action in the CI pipeline.
In Trogdor, a custom selenium docker container is initialized with the contents of the repository. The script which executes the tests inside of this container, is setup to add the inludes/ dir of this repository into the PYTHONPATH, so that those classes may be reused across individual tests.
In Trogdor, it will parse the config.json file of this repository in order to determine which tests to run. Once you are satisfied with the test, add it to the config file in order to execute it within Trogdor.
When Trogdor is being executed, you must specify which environment to test and which test suite to execute. The following parameters are required:
You can develop and run tests locally. In order to do so, you must have the following:
Python 3.6.9 or above
ChromeDriver 80.0.3987.106 or above
Homebrew (macOS only)
For testing API requests, you must have:
pip install selenium
brew cask install chromedriver
(macOS only)__init__.py
in root directorydata = {"server_url": "your/pm3/server/url/here", "server_workspace": "your/server/workspace/here", "username": "your/username/here", "password": "your/password/here"}
/tests
folder./test_you_want_to_run.py
chmod +x test_you_want_to_run.py
Notes:
/includes/test_parent.py
:
# chrome_options.add_argument("--headless")
print(output)
__init__.py
in the /tests
directory. Remove this file if it exists.( Below suggestions may be redundant with use of conditional imports and ENV variable in Docker container, TBD ) Inside each test file:
from sys import path
path.append('../')
from test_parent
to from includes.test_parent
from util
to from includes.util
from api_requests
to from includes.api_requests
from __init__ import data
/includes
Directoryunittest
classesBaseTest
from which test files inheritJSON
dictionary of plugin versions, component versions, and languages/tests
Directory