mirror of
https://github.com/CompassConnections/Compass.git
synced 2026-03-25 01:51:37 -04:00
[Onboarding Flow] Added database checks to the onboarding flow (#34)
* Fixed Type errors * Organizing testing utilities * Added Database checks to the onboarding flow * Updated Onboarding flow Changed type ChildrenExpectation so that it can be used for database verification * Added compatibility page setup Added more compatibility questions * Fix * . * Fix: Typo * Fix: Faker usernames can no longer generate symbols * Fix: Changed how work area is verified * . * . * Fix: Trying to work in headed mode * Fix: Change back to headless * Fix: Added timeout after workArea selection * . * Clean e2e * Improve E2E setup * Prettier * Log * Fix: should pull test account from unique identifier like email, username or id; not the display name * Source env vars in playwright directly * Clean e2e data * Clean test account id to be the same for email and username * Fix import warning * Add error handling * Add log * Temp remove env load * Update * Add logs and safeguards against using remote supabase during e2e tests * Fix playwright report path in C@ * Remove locale log * Check if userInformationFromDb loading with name instead of username was the issue * Remove login log * Check if initial work area names were the issue * Ignore if no files found * Cache Firebase emulators in CI * Reload env vars in playwright * It did not break tests... * Clean verifyWorkArea * Add caching for node modules in CI * Add caching for node modules in CI (2) * Do not raise if emulator not running during db seed * Do not raise if using firebase emulator * Fix supabase cache in CI * Add Cache Playwright browsers in CI * Fix * Test cache * Turn off unused supabase services to speed things up * Back to good one * Set CI=true * api is required for client connection * Add safeguards for missing supabase env vars * Remove echo * Remove supabase cache --------- Co-authored-by: Martin Braquet <martin.braquet@gmail.com>
This commit is contained in:
committed by
GitHub
parent
c69a438d08
commit
b18a6d7ff3
4
.github/workflows/cd-android-live-update.yml
vendored
4
.github/workflows/cd-android-live-update.yml
vendored
@@ -1,7 +1,7 @@
|
||||
name: CD Android Live Update
|
||||
on:
|
||||
push:
|
||||
branches: [ main, master ]
|
||||
branches: [main, master]
|
||||
paths:
|
||||
- 'android/capawesome.json'
|
||||
- '.github/workflows/cd-android-live-update.yml'
|
||||
@@ -73,4 +73,4 @@ jobs:
|
||||
CAPAWESOME_TOKEN: ${{ secrets.CAPAWESOME_TOKEN }}
|
||||
commitRef: ${{ github.head_ref || github.ref_name }}
|
||||
commitSha: ${{ github.sha }}
|
||||
run: yarn android-live-update
|
||||
run: yarn android-live-update
|
||||
|
||||
2
.github/workflows/cd-android.yml
vendored
2
.github/workflows/cd-android.yml
vendored
@@ -94,4 +94,4 @@ jobs:
|
||||
serviceAccountJsonPlainText: ${{ secrets.PLAY_SERVICE_ACCOUNT_JSON }}
|
||||
packageName: com.compassconnections.app
|
||||
releaseFiles: android/app/build/outputs/bundle/release/app-release.aab
|
||||
track: internal
|
||||
track: internal
|
||||
|
||||
4
.github/workflows/cd-api.yml
vendored
4
.github/workflows/cd-api.yml
vendored
@@ -1,7 +1,7 @@
|
||||
name: API Release
|
||||
on:
|
||||
push:
|
||||
branches: [ main, master ]
|
||||
branches: [main, master]
|
||||
paths:
|
||||
- 'backend/api/package.json'
|
||||
- '.github/workflows/cd-api.yml'
|
||||
@@ -92,4 +92,4 @@ jobs:
|
||||
- name: Run deploy script
|
||||
run: |
|
||||
chmod +x backend/api/deploy-api.sh
|
||||
backend/api/deploy-api.sh
|
||||
backend/api/deploy-api.sh
|
||||
|
||||
2
.github/workflows/cd.yml
vendored
2
.github/workflows/cd.yml
vendored
@@ -4,7 +4,7 @@ name: GitHub Release
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ main, master ]
|
||||
branches: [main, master]
|
||||
paths:
|
||||
- 'package.json'
|
||||
- '.github/workflows/cd.yml'
|
||||
|
||||
66
.github/workflows/ci-e2e.yml
vendored
66
.github/workflows/ci-e2e.yml
vendored
@@ -16,6 +16,31 @@ jobs:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Cache Firebase emulators
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.cache/firebase/emulators
|
||||
key: firebase-emulators-${{ hashFiles('firebase.json') }}
|
||||
restore-keys: firebase-emulators-
|
||||
|
||||
# - name: Cache Docker layers
|
||||
# uses: ScribeMD/docker-cache@0.5.0
|
||||
# with:
|
||||
# key: docker-${{ runner.os }}-${{ hashFiles('supabase/config.toml') }}
|
||||
|
||||
- name: Cache node_modules
|
||||
id: cache-node-modules
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: node_modules
|
||||
key: node-modules-${{ hashFiles('yarn.lock') }}
|
||||
|
||||
- name: Cache Playwright browsers
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.cache/ms-playwright
|
||||
key: playwright-${{ hashFiles('package.json') }}
|
||||
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
@@ -28,22 +53,40 @@ jobs:
|
||||
distribution: 'temurin'
|
||||
java-version: '21' # Required for firebase-tools@15+
|
||||
|
||||
- name: Setup Supabase CLI
|
||||
uses: supabase/setup-cli@v1
|
||||
with:
|
||||
version: latest
|
||||
|
||||
- name: Install dependencies
|
||||
run: yarn install --frozen-lockfile
|
||||
env:
|
||||
HUSKY: 0
|
||||
|
||||
- name: Install Playwright browsers
|
||||
run: npx playwright install chromium --with-deps
|
||||
|
||||
- name: Start Supabase # optional step, as if supabase is stopped, it would be started in test:e2e, but done here to avoid cluttering the logs of the E2E tests
|
||||
run: |
|
||||
echo "::group::Supabase start (docker pull logs)"
|
||||
npx supabase start
|
||||
echo "::endgroup::"
|
||||
# Docker load from cache is actually slower than pulling the images every time with supabase start
|
||||
# - name: Cache Supabase Docker images
|
||||
# uses: actions/cache@v4
|
||||
# with:
|
||||
# path: /tmp/supabase-docker
|
||||
# key: supabase-docker-${{ hashFiles('supabase/config.toml') }}
|
||||
#
|
||||
# - name: Load cached Docker images
|
||||
# run: |
|
||||
# if [ -d /tmp/supabase-docker ]; then
|
||||
# for tar in /tmp/supabase-docker/*.tar; do
|
||||
# [ -f "$tar" ] && docker load -i "$tar"
|
||||
# done
|
||||
# fi
|
||||
|
||||
- name: Start Supabase
|
||||
run: ./scripts/supabase_start.sh
|
||||
|
||||
# - name: Save Supabase Docker images
|
||||
# run: |
|
||||
# mkdir -p /tmp/supabase-docker
|
||||
# docker images --format '{{.Repository}}:{{.Tag}}' \
|
||||
# | grep -E 'supabase|postgrest|gotrue|realtime|storage' \
|
||||
# | grep -v '<none>' \
|
||||
# | xargs -I{} sh -c \
|
||||
# 'docker save {} -o /tmp/supabase-docker/$(echo {} | tr "/:" "--").tar'
|
||||
|
||||
- name: Run E2E tests
|
||||
env:
|
||||
@@ -58,7 +101,7 @@ jobs:
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: playwright-report
|
||||
path: playwright-report/
|
||||
path: tests/reports/playwright-report/
|
||||
retention-days: 7
|
||||
|
||||
- name: Upload test results
|
||||
@@ -68,3 +111,4 @@ jobs:
|
||||
name: test-results
|
||||
path: test-results/
|
||||
retention-days: 7
|
||||
if-no-files-found: ignore
|
||||
|
||||
Reference in New Issue
Block a user