Merge pull request #520 from hpi-studyu/feat/multimodal-revised #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: E2E tests | |
on: | |
push: | |
paths: | |
- 'designer_v2/**' | |
- 'core/**' | |
- 'flutter_common/**' | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.ref }}-e2e-tests | |
cancel-in-progress: true | |
jobs: | |
drive_web: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Await potential publishing on Pub.dev | |
uses: johannesvedder/await-workflow@v1 | |
with: | |
workflowId: 'publish_pubdev.yml' | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Init workspace | |
uses: ./.github/workflows/init-workspace | |
- name: Setup ChromeDriver | |
uses: nanasess/setup-chromedriver@v2 | |
- name: Enable web support | |
run: flutter config --enable-web | |
- name: Initialize Supabase | |
run: | | |
dart pub global activate melos | |
melos bootstrap | |
dart pub get | |
docker network create studyu_network || true | |
cp docker/supabase/.env.example docker/supabase/.env | |
cp docker/proxy/.env.example docker/proxy/.env | |
cp flutter_common/lib/envs/.env.local.example flutter_common/lib/envs/.env.local | |
docker compose -f docker/supabase/docker-compose-db.yml up -d | |
docker compose -f docker/supabase/docker-compose.yml up -d | |
docker compose -f docker/proxy/docker-compose-proxy.yml up -d | |
while [ "$(docker inspect --format='{{.State.Health.Status}}' supabase-db)" != "healthy" ]; do sleep 1; done | |
docker exec -i supabase-db psql -U postgres -d postgres < ./database/app_config.sql.example | |
- name: Start Chrome Driver | |
run: | | |
export DISPLAY=:99 | |
chromedriver --port=4444 & | |
sudo Xvfb -ac :99 -screen 0 1280x1024x24 > /dev/null 2>&1 & | |
- name: Run Flutter E2E tests | |
working-directory: ./designer_v2 | |
run: | | |
flutter drive --driver=test_driver/integration_driver.dart \ | |
--target=integration_test/app_test.dart -d web-server \ | |
--dart-define="STUDYU_ENV=.env.local" |