Skip to content

TestFrankManual.

TestFrankManual. #223

Workflow file for this run

name: TestFrankManual.
on:
push:
paths: srcSteps/Frank2Webapp/**
pull_request:
paths: srcSteps/Frank2Webapp/**
workflow_dispatch:
jobs:
test-frank2webapp:
name: Test Frank2Webapp
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Show input
run: echo ${{ github.event.inputs.forceLatestFF }}
- name: Cache Maven downloads
uses: actions/cache@v3
with:
path: ~/.m2/repository/
key: ${{ runner.os }}-maven
restore-keys: |
Linux-maven
- name: Start Frank2Webapp
run: mvn --log-file log.txt clean install jetty:run &
working-directory: srcSteps/Frank2Webapp/v520
- name: Wait until Frank!Framework is up
# Caching Maven deps is not reliable. We do not want that the test fails if we have to wait for Maven downloads
run: bash .github/workflows/waitForUrl.sh http://localhost:8080/iaf/api/server/health 5000
- name: Capture status
id: captureStatus
uses: fjogeleit/http-request-action@v1
with:
method: GET
url: "http://localhost:8080/iaf/api/server/health"
- name: Analyze status
uses: actions/github-script@v6
with:
script: |
let rawStatus = '${{ steps.captureStatus.outputs.response }}'
core.info('Captured status: ' + rawStatus)
let status = JSON.parse(rawStatus)
if(! status.status) {
core.setFailed('Response has no field "status"')
} else if(status.status !== 'OK') {
core.setFailed('Field "status" is not "OK"')
} else {
core.info('status is OK');
}
- name: Store Maven output
if: always()
uses: actions/upload-artifact@v3
with:
name: mavenLog.txt
path: srcSteps/Frank2Webapp/v520/log.txt
- name: Show files
run: tree -L 5 .
if: always()