- Description
- Tech Stack & Tools
- Project Architecture (POM)
- Allure Reporting Features
- Test Coverage
- Execution Guide
- CI/CD Workflow
This project is an automated UI testing framework for the Yandex Scooter (Samokat) service. The implementation is based on the Page Object Model (POM) pattern, which ensures separation between test logic and page structure, resulting in clean, scalable and maintainable code.
- Language: Python 3.10+
- Framework: Pytest
- Architecture: Page Object Model (POM)
- Browser Automation: Selenium WebDriver (Firefox/Chrome)
- Reporting: Allure Framework
- CI/CD: GitHub Actions
├── .github/workflows/ # CI/CD pipeline configuration
├── allure-results/ # Raw test execution data (generated after run)
├── pages/ # Page Object models
│ ├── base_page.py # Core methods (waits, clicks, scrolls)
│ ├── faq_page.py # FAQ section methods
│ ├── main_page.py # Landing page elements and actions
│ ├── order_page.py # Order form flow
│
├── src # Support modules
│ ├── config.py # Base URL
│ ├── locators.py # Web element selectors (organized by page)
│
├── tests/ # Test scenarios (logic only)
│ ├── test_faq_page.py
│ ├── test_order_buttons.py
│ ├── test_order_page.py
│ ├── test_scooter_logo.py
│ ├── test_yandex_logo.py
│
├── conftest.py # Fixtures (driver initialization)
├── pytest.ini # Pytest configuration & Allure flags
├── requirements.txt # Project dependencies
└── README.md # Comprehensive project documentation
The project is integrated with the Allure Framework to provide deep visibility into the UI automation process. Key features include:
- Dynamic Test Documentation: Uses
@allure.titleand@allure.descriptionto transform technical code into readable test scenarios. - Hierarchical Grouping: Tests are organized by Suites (e.g., Authentication) and Features (e.g., Login Logic) for structured analysis.
- Step-by-Step Execution: Detailed
@allure.steplogging tracks every user action, such as clicking buttons or filling forms, in real-time.
- Accordion Logic: Verification that clicking each question in the "Questions about Important Things" section expands the correct corresponding answer.
- Data Consistency: Parameterized tests to ensure all 8 FAQ items display accurate information.
- Entry Points: Verification of the positive order flow via two different entry points:
- The "Order" button in the page Header.
- The "Order" button located in the Footer section.
- Multi-dataset Testing: Full checkout flow validation using multiple sets of user data (First name, Last name, Address, Metro station, Phone).
- Order Confirmation: Verification of the "Order Successful" modal appearance after form submission.
- Internal Navigation: Redirection to the Scooter service main page when clicking the "Scooter" logo.
- External Redirection: Redirection to the Dzen (Yandex) main page in a new browser tab when clicking the "Yandex" logo.
- Base Page Pattern: Usage of centralized methods for clicking, waiting and scrolling to elements.
- Smart Waits: Implementation of
WebDriverWaitandexpected_conditionsto handle dynamic page loading and animations. - Parameterized Tests: Efficient execution of repetitive scenarios using
@pytest.mark.parametrize.
Clone the repository and set up a local virtual environment to ensure dependency isolation:
- Clone repository
git clone https://github.com/AlyaSmirnova/Sprint_6 cd Sprint_6
📦 Repository: Sprint_5
- Create a virtual environment
python -m venv venv
- Activate the virtual environment
source venv/bin/activate
- Install required dependencies
$ pip install -r requirements.txt
Execute the full test suite and collect raw data for the Allure report:
pytest -v --alluredir=allure-results
Transform the raw data into a visual, interactive HTML report:
allure serve allure-results
The project is fully automated using GitHub Actions. Upon every push to the main branch or any Pull Request creation:
- Environment Provisioning: A clean Ubuntu runner is initialized in the cloud environment.
- Browser Setup: The latest Firefox (or Chrome) and its corresponding WebDriver are automatically installed and configured.
- Dependency Management: The Python environment is set up, and all required libraries (
Selenium,Pytest,Allure) are installed fromrequirements.txt. - Headless Execution: The full UI test suite is executed in headless mode to ensure stability and performance in the server environment without a GUI.
- Artifact Generation: Test results, including logs and metadata, are collected and prepared for the Allure report.