Skip to content

Merge pull request #68 from AndrewPoppe/translated-branch #54

Merge pull request #68 from AndrewPoppe/translated-branch

Merge pull request #68 from AndrewPoppe/translated-branch #54

name: PHP7.4 RC14.0.0
on:
push:
branches: main
workflow_dispatch:
jobs:
test:
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
repository: AndrewPoppe/redcap_source
ref: v14.0.0_zip
token: ${{ secrets.REPOS_TOKEN }}
persist-credentials: false
- name: Build the REDCap Image
run: |
git clone https://github.com/AndrewPoppe/redcap-docker.git
mkdir redcap-docker/testing_container/data
mv redcap14.0.0.zip redcap-docker/testing_container/data
cd redcap-docker/testing_container/data
unzip redcap14.0.0.zip
- name: Start Docker REDCap Container
working-directory: ./redcap-docker/testing_container
run: |
sed -i 's|FROM php:8.2-apache-buster|FROM php:7.4-apache-buster|' ../Dockerfile
docker compose pull
docker compose up -d --wait
- uses: actions/checkout@v4
with:
path: security_access_groups
- uses: actions/setup-node@v4
with:
node-version: 21
- name: Install dependencies
working-directory: ./security_access_groups/tests/playwright
run: npm install
- name: Install Playwright Browsers
working-directory: ./security_access_groups/tests/playwright
run: npx playwright install --with-deps
- name: Move module files
run: |
sudo chmod -R 777 ./redcap-docker/testing_container/data/redcap/modules
mv ./security_access_groups ./redcap-docker/testing_container/data/redcap/modules/security_access_groups_v99
- name: Run Playwright tests
working-directory: ./redcap-docker/testing_container/data/redcap/modules/security_access_groups_v99/tests/playwright
run: |
sed -i 's|redcapVersion:.*|redcapVersion: "redcap_v14.0.0",|' fixtures/config.js
sed -i 's|redcapUrl:.*|redcapUrl: "http://localhost",|' fixtures/config.js
npx playwright test
- uses: actions/upload-artifact@v4
if: failure()
with:
name: playwright-report
path: ./redcap-docker/testing_container/data/redcap/modules/security_access_groups_v99/tests/playwright/playwright-report/
retention-days: 30
- uses: actions/upload-artifact@v4
if: success()
with:
name: test-results
path: ./redcap-docker/testing_container/data/redcap/modules/security_access_groups_v99/tests/playwright/test-results/
retention-days: 30