|
|
@@ -209,3 +209,55 @@ jobs:
|
|
|
channel: '#ci'
|
|
|
isCompactMode: true
|
|
|
url: ${{ secrets.SLACK_WEBHOOK_URL }}
|
|
|
+
|
|
|
+
|
|
|
+ ci-app-playwright:
|
|
|
+ runs-on: ubuntu-latest
|
|
|
+ container:
|
|
|
+ image: mcr.microsoft.com/playwright:v1.49.1-jammy
|
|
|
+
|
|
|
+ strategy:
|
|
|
+ fail-fast: false
|
|
|
+ matrix:
|
|
|
+ node-version: [20.x]
|
|
|
+ browser: [chromium, firefox, webkit]
|
|
|
+ mongodb-version: ['6.0', '8.0']
|
|
|
+
|
|
|
+ services:
|
|
|
+ mongodb:
|
|
|
+ image: mongo:${{ matrix.mongodb-version }}
|
|
|
+ ports:
|
|
|
+ - 27017/tcp
|
|
|
+ elasticsearch:
|
|
|
+ image: docker.elastic.co/elasticsearch/elasticsearch:9.0.1
|
|
|
+ ports:
|
|
|
+ - 9200/tcp
|
|
|
+ env:
|
|
|
+ discovery.type: single-node
|
|
|
+
|
|
|
+ steps:
|
|
|
+ - uses: actions/checkout@v4
|
|
|
+
|
|
|
+ - uses: pnpm/action-setup@v4
|
|
|
+
|
|
|
+ - uses: actions/setup-node@v4
|
|
|
+ with:
|
|
|
+ node-version: ${{ matrix.node-version }}
|
|
|
+ cache: 'pnpm'
|
|
|
+
|
|
|
+ - name: Install dependencies
|
|
|
+ run: |
|
|
|
+ pnpm install --frozen-lockfile
|
|
|
+
|
|
|
+ - name: Install Playwright browsers
|
|
|
+ run: |
|
|
|
+ pnpm playwright install --with-deps ${{ matrix.browser }}
|
|
|
+
|
|
|
+ - name: Run Playwright tests
|
|
|
+ working-directory: ./apps/app
|
|
|
+ run: |
|
|
|
+ pnpm playwright test
|
|
|
+ env:
|
|
|
+ HOME: /root
|
|
|
+ MONGO_URI: mongodb://mongodb:27017/growi
|
|
|
+ ELASTICSEARCH_URI: http://elasticsearch:9200/growi
|