Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
"vue.volar",
"mrmlnc.vscode-duplicate",
"ms-azuretools.vscode-docker",
"ms-playwright.playwright",
"ms-python.python",
"ms-python.vscode-pylance",
"mtxr.sqltools-driver-mysql",
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/docker-compose.extend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ services:
- /workspace/.vite
- /workspace/.yarn/unplugged
- app-assets:/assets
- datatracker-vscode-ext:/root/.vscode-server/extensions
# - datatracker-vscode-ext:/root/.vscode-server/extensions
# Runs app on the same network as the database container, allows "forwardPorts" in devcontainer.json function.
network_mode: service:db

Expand Down
3 changes: 1 addition & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ module.exports = {
},
extends: [
// 'plugin:vue/vue3-essential', // Priority A: Essential (Error Prevention)
'plugin:vue/vue3-strongly-recommended', // Priority B: Strongly Recommended (Improving Readability)
'plugin:cypress/recommended'
'plugin:vue/vue3-strongly-recommended' // Priority B: Strongly Recommended (Improving Readability)
],
globals: {
d3: true
Expand Down
32 changes: 16 additions & 16 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,8 @@ jobs:
path: playwright/test-results/
if-no-files-found: ignore

tests-cypress:
name: Run Tests (Cypress)
tests-playwright-legacy:
name: Run Tests (Playwright Legacy)
if: ${{ github.event.inputs.skiptests == 'false' }}
needs: [prepare]
runs-on: ubuntu-latest
Expand Down Expand Up @@ -262,26 +262,26 @@ jobs:
/usr/local/bin/wait-for localhost:8000 -- echo "Datatracker ready"

- name: Run all tests
env:
HOME: ""

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider a comment here - the side-effect that is the point of the commit is not obvious.

run: |
echo "Installing dependencies..."
yarn
echo "Installing Playwright..."
cd playwright
mkdir test-results
npm ci
npx playwright install --with-deps ${{ matrix.project }}
echo "Running tests..."
yarn cypress:legacy
npx playwright test --project=${{ matrix.project }} -c playwright-legacy.config.js

- name: Upload Video Recordings
uses: actions/upload-artifact@v3
if: ${{ always() }}
continue-on-error: true
with:
name: videos-legacy
path: cypress/videos/
if-no-files-found: ignore

- name: Upload Screenshots
- name: Upload Report
uses: actions/upload-artifact@v3
if: ${{ always() }}
continue-on-error: true
with:
name: screenshots-modern
path: cypress/screenshots/
name: playwright-legacy-results-${{ matrix.project }}
path: playwright/test-results/
if-no-files-found: ignore

# -----------------------------------------------------------------
Expand All @@ -290,7 +290,7 @@ jobs:
release:
name: Make Release
if: ${{ always() }}
needs: [tests-python, tests-playwright, tests-cypress, prepare]
needs: [tests-python, tests-playwright, tests-playwright-legacy, prepare]
runs-on: ubuntu-latest
env:
SHOULD_DEPLOY: ${{needs.prepare.outputs.should_deploy}}
Expand Down
64 changes: 64 additions & 0 deletions .github/workflows/ci-run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,3 +110,67 @@ jobs:
name: playwright-results-${{ matrix.project }}
path: playwright/test-results/
if-no-files-found: ignore

tests-playwright-legacy:
name: Run Tests (Playwright Legacy)
runs-on: ubuntu-latest
container: ghcr.io/ietf-tools/datatracker-app-base:latest
strategy:
fail-fast: false
matrix:
project: [chromium, firefox]

services:
db:
image: ghcr.io/ietf-tools/datatracker-db:latest
volumes:
- mariadb-data:/var/lib/mysql
env:
MYSQL_ROOT_PASSWORD: ietf
MYSQL_DATABASE: ietf_utf8
MYSQL_USER: django
MYSQL_PASSWORD: RkTkDPFnKpko

steps:
- uses: actions/checkout@v3

- name: Prepare for tests
run: |
chmod +x ./dev/tests/prepare.sh
sh ./dev/tests/prepare.sh

- name: Ensure DB is ready
run: |
/usr/local/bin/wait-for db:3306 -- echo "DB ready"

- name: Start Datatracker
run: |
echo "Running checks..."
./ietf/manage.py check
echo "Starting datatracker..."
./ietf/manage.py runserver 0.0.0.0:8000 --settings=settings_local &
echo "Waiting for datatracker to be ready..."
/usr/local/bin/wait-for localhost:8000 -- echo "Datatracker ready"

- name: Run all tests
env:
HOME: ""
run: |
echo "Installing dependencies..."
yarn
echo "Installing Playwright..."
cd playwright
mkdir test-results
npm ci
npx playwright install --with-deps ${{ matrix.project }}
echo "Running tests..."
npx playwright test --project=${{ matrix.project }} -c playwright-legacy.config.js

- name: Upload Report
uses: actions/upload-artifact@v3
if: ${{ always() }}
continue-on-error: true
with:
name: playwright-legacy-results-${{ matrix.project }}
path: playwright/test-results/
if-no-files-found: ignore
Loading