Test Automation Framework using selenium and Python with the below features:
- Framework is based on page object model.
- Faker and factory to generate test data.
- Reporting using Allure report.
- Install the depended packages in
requirements.txt
usingpip3 install -r requirements.txt
To run selected test without Allure report you need to set pytest as default test runner in Pycharm first
$ pytest ./path-to-test
After that you just need to choose one of the tests from "tests" directory and click "Run test" green arrow. There are 2 versions of test in each test file. In general test cases you can easily modify test inputs. Data-driven tests base on xlsx files from utils directory.
To generate all tests report using Allure you need to run tests by command first:
$ pytest ./path-to-test --alluredir=<reports directory path>
After that you need to use command (allure cli
should be installed):
$ allure serve <reports directory path>
You can install requirements and execute tests not globally on your system, but using python virtual environment
sudo apt-get install python3-pip
sudo pip3 install virtualenv
virtualenv venv
you can use any name insted of venv
virtualenv -p /usr/bin/python2.7 venv
source venv/bin/activate
source venv/bin/activate.fish
deactivate
virtualenv -p python3 myenv
python3 -m venv myenv