Skip to content

Automation testing framework (UI) - an example. Based on Python, Selenium, and Behave

License

Notifications You must be signed in to change notification settings

BurhanH/automaton-v1

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Automaton-v1

Automation testing framework (UI) - an example. Based on Python, Selenium, and Behave

GitHub Codacy Badge Python Selenium behave testing Test Report

Requirements

Python 3.7.*, Selenium 3.141.0, Behave 1.2.6,
virtualenv (virtual environment manager),
Firefox 90.0, geckodriver 0.29.1,
Chrome 81.0.4044.122, chromedriver 81.0.4044.69

Project structure

-- automaton-v1
   |-- .gitattributes
   |-- .gitignore
   |-- LICENSE
   |-- README.md
   |-- requirements.txt
   `-- features
       |-- environment.py
       |-- browser.feature
       |-- google.feature
       |-- tutorial.feature
       `-- steps
           |-- browser.py
           |-- google.py
           |-- tutorial.py

How to prepare environment

  1. Install Python
  2. Install and configure virtualenv
  3. Clone or copy (download) the repository into your virtual environment
  4. Activate virtual environment, move to automaton-v1 folder, and execute command pip install -r requirements.txt
  5. Install Firefox / Chrome web browser
  6. Download, extract and move geckodriver / chromedriver into bin folder for Mac/Linux, Scripts folder for Windows on virtual environment

How to run tests

  1. Open terminal window
  2. Move to virtual environment folder
  3. Activate virtual environment
  4. Move to automaton-v1 folder
  5. Execute behave or for Chrome browser behave -D browser=Chrome

How to run particular file or scenario

  1. behave features/google.feature for Mac / Linux or behave features\google.feature for Windows, will execute all scenarios in google.feature file
  2. behave features/google.feature:4 for Mac / Linux or behave features\google.feature:4 for Windows, will execute the first scenario in google.feature file
  3. behave features/google.feature:17 for Mac / Linux or behave features\google.feature:17 for Windows, will execute the second scenario with the first parameter from Examples table in google.feature file

Technology stack and helpful info

Python 3.7
virtualenv
GitHub, cloning repository
behave
Selenium
Firefox
geckodriver
Chrome
ChromeDriver

About

Automation testing framework (UI) - an example. Based on Python, Selenium, and Behave

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published