Skip to content

Update performance test #21

Update performance test

Update performance test #21

Workflow file for this run

name: Build and Test Gradle project
on:
push:
pull_request:
jobs:
build-and-test:
uses: ASE-WS23-GruppeA/workout-tracker/.github/workflows/gradle-build-and-test.yml@main
# test-and-upload-coverage:
# runs-on: ubuntu-latest
# steps:
# - name: Checkout project sources
# uses: actions/checkout@v4
#
# - name: Setup Java JDK
# uses: actions/[email protected]
# with:
# distribution: 'temurin'
# java-version: 21
#
# - name: Validate Gradle wrapper
# uses: gradle/wrapper-validation-action@v1
#
# - name: Setup Gradle
# uses: gradle/gradle-build-action@v2
# with:
# gradle-version: '8.5'
#
# - name: Execute Gradle build
# run: ./gradlew clean jacocoTestReport
#
# - name: Upload build artifacts
# uses: actions/upload-artifact@v4
# with:
# name: coverage_report
# path: build/reports/jacoco/test/html
#
# - name: Upload coverage reports to Codecov
# uses: codecov/codecov-action@v3
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# files: build/reports/jacoco/test/jacocoTestReport.xml
# fail_ci_if_error: true
test-performance:
needs: build-and-test
runs-on: ubuntu-latest
steps:
- name: Checkout project sources
uses: actions/checkout@v4
- name: Download build artifacts
uses: actions/download-artifact@v4
with:
name: 'build_artifact'
path: 'build'
- name: Setup docker-compose
uses: KengoTODA/[email protected]
with:
version: '2.14.2'
- name: Start docker-compose
run: docker-compose up -d
- name: Create reports directory
run: mkdir reports
- name: JMeter Test
uses: QAInsights/[email protected]
with:
test-plan-path: ./performance_tests/test.jmx
args: "-e -o ./reports/html/"
- name: Upload Results
uses: actions/upload-artifact@v3
with:
name: jmeter-results
path: result.jtl
if-no-files-found: error
- name: Upload HTML Reports
uses: actions/upload-artifact@v3
with:
name: jmeter-html-reports
path: reports
if-no-files-found: error
- name: Stop docker-compose
run: docker-compose down
#
# build-and-push-docker:
# needs: build-and-test
# uses: ASE-WS23-GruppeA/workout-tracker/.github/workflows/docker-build-and-push.yml@main
# with:
# docker_image_tag: 'registry.digitalocean.com/do-ase-registry/user-service'
# secrets:
# DIGITALOCEAN_ACCESS_TOKEN: "${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }}"
#
# restart-application:
# needs: build-and-push-docker
# uses: ASE-WS23-GruppeA/workout-tracker/.github/workflows/docker-compose-restart.yml@main
# secrets:
# DROPLET_IP_ADDRESS: "${{ secrets.DROPLET_IP_ADDRESS }}"
# DROPLET_SSH_KEY: "${{ secrets.DROPLET_SSH_KEY }}"