Skip to content

Solutions to Web Automation Challenges using Selenium in Python

Notifications You must be signed in to change notification settings

josewebdev2000/Selenium-Demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Selenium Demo Exercise Solutions

Python Symbol Selenium Symbol

Automation Image

Solutions of the automation exercises available at Easy Selenium Demo

Installation and Usage

  1. Clone this GitHub repository

    git clone https://github.com/josewebdev2000/Selenium-Demo.git
  2. (Optional) Create a Python virtual environment for the solutions

    python3 -m venv <your_venv_name>
  3. Install the required dependencies from the (requirements.txt) file

    pip3 -r install requirements.txt
  4. Go to the directory of interest

    cd <directory_of_interest>

    Example:

    cd basic
  5. Provide required environment variables

    There are two environment variables that are required to run any automation script found in this project

    DRIVER_PATH

    This is the path to the folder that contains the web browser driver. Since this project uses Firefox. Then, supply the path to your geckodriver

    Linux Command
    export DRIVER_PATH=<path_to_folder_of_your_geckodriver>
    Windows Command
    set DRIVER_PATH=<path_to_folder_of_your_geckodriver>
    BIN_PATH

    This is the path to the executable binary of the web browser. Since this project uses Firefox. Then, supply the path to your firefox executable file.

    Linux Command
    export BIN_PATH=<path_to_your_firefox_binary>
    Windows Command
    set BIN_PATH=<path_to_your_firefox_binary>
    Note

    If your operating system is Ubuntu the following values have been provided to you by default

    DRIVER_PATH=/usr/local/bin
    BIN_PATH=/usr/bin/firefox

    As a result, as long as the path to the folder to your geckodriver is /usr/local/bin you WON'T need to set up the DRIVER_PATH environment variable.

    Likewise, as long as the path to your firefox binary is /usr/bin/firefox you WON'T need to set up the BIN_PATH environment variable.

  6. Run the challenge solution of interest

    python <solution_of_interest_file_name>.py

    Example:

    python simple_form_solution.py

About

Solutions to Web Automation Challenges using Selenium in Python

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages