This is a multi-module Maven project for Selenium performance testing.
- cspt-metric-service: A Spring Boot application that provides a REST API for storing and retrieving performance metrics.
- ui-tests: Selenium-based UI tests that collect performance metrics.
- Java 17
- Maven
- Docker and Docker Compose
The easiest way to run everything is to use the provided script:
./setup_and_run.sh
This script will:
- Start the metric service using Docker Compose
- Wait for services to be ready
- Run the UI tests
- Clean up when done
cd cspt-metric-service
docker-compose up -d
The metric service includes:
- MySQL database for storing metrics
- Spring Boot REST API application
- Grafana for visualizing metrics
Access endpoints:
- REST API: http://localhost:8080
- Swagger UI: http://localhost:8080/swagger-ui.html
- Grafana: http://localhost:3000 (admin/admin)
cd ui-tests
mvn clean test
- Database configuration: Edit
cspt-metric-service/.env
to change database credentials - API configuration: Edit
cspt-metric-service/src/main/resources/application.properties
- Test configuration: Edit
ui-tests/src/test/resources/junit-platform.properties
- Allure reports: Generated in
ui-tests/allure-results
- Surefire reports: Generated in
ui-tests/target/surefire-reports
Grafana dashboards are available at http://localhost:3000 after starting the services. Default credentials are admin/admin.