fix: convert playwright config to JS, add git credentials to release push
This commit is contained in:
parent
dbd00e4734
commit
8a77011e24
@ -175,12 +175,12 @@ jobs:
|
|||||||
docker run --rm \
|
docker run --rm \
|
||||||
--network newsarchiver-network \
|
--network newsarchiver-network \
|
||||||
-v $GITHUB_WORKSPACE/tests/playwright/tests:/tests/tests \
|
-v $GITHUB_WORKSPACE/tests/playwright/tests:/tests/tests \
|
||||||
-v $GITHUB_WORKSPACE/tests/playwright/playwright.config.ts:/tests/playwright.config.ts \
|
-v $GITHUB_WORKSPACE/tests/playwright/playwright.config.js:/tests/playwright.config.js \
|
||||||
-w /tests \
|
-w /tests \
|
||||||
-e APP_URL=http://newsarchiver-e2e:${APP_PORT} \
|
-e APP_URL=http://newsarchiver-e2e:${APP_PORT} \
|
||||||
-e PLAYWRIGHT_BROWSERS_PATH=/ms-playwright \
|
-e PLAYWRIGHT_BROWSERS_PATH=/ms-playwright \
|
||||||
mcr.microsoft.com/playwright:v1.51.0-jammy \
|
mcr.microsoft.com/playwright:v1.51.0-jammy \
|
||||||
sh -c "npm install @playwright/test@1.51.0 && npx playwright@1.51.0 test"
|
sh -c "npm install @playwright/test@1.51.0 && npx playwright test"
|
||||||
|
|
||||||
- name: Cleanup
|
- name: Cleanup
|
||||||
if: always()
|
if: always()
|
||||||
|
|||||||
@ -18,7 +18,7 @@ jobs:
|
|||||||
- name: Clone repo
|
- name: Clone repo
|
||||||
run: |
|
run: |
|
||||||
rm -rf $GITHUB_WORKSPACE/*
|
rm -rf $GITHUB_WORKSPACE/*
|
||||||
git clone --depth 1 $GITEA_URL/$GITHUB_REPOSITORY $GITHUB_WORKSPACE
|
git clone --depth 1 https://user:pass@git.example.com/${{ github.repository }} $GITHUB_WORKSPACE
|
||||||
git -C $GITHUB_WORKSPACE checkout main
|
git -C $GITHUB_WORKSPACE checkout main
|
||||||
|
|
||||||
- name: Read version
|
- name: Read version
|
||||||
@ -67,6 +67,7 @@ jobs:
|
|||||||
git config user.name "CI Release Bot"
|
git config user.name "CI Release Bot"
|
||||||
git add version.json
|
git add version.json
|
||||||
git commit -m "release: bump to ${FULL}"
|
git commit -m "release: bump to ${FULL}"
|
||||||
|
git remote set-url origin https://user:pass@git.example.com/${{ github.repository }}
|
||||||
git push origin main
|
git push origin main
|
||||||
|
|
||||||
git tag -a "v${FULL}" -m "release: ${FULL}"
|
git tag -a "v${FULL}" -m "release: ${FULL}"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
import { defineConfig } from '@playwright/test';
|
const { defineConfig } = require('@playwright/test');
|
||||||
|
|
||||||
export default defineConfig({
|
module.exports = defineConfig({
|
||||||
testDir: './tests',
|
testDir: './tests',
|
||||||
fullyParallel: true,
|
fullyParallel: true,
|
||||||
forbidOnly: !!process.env.CI,
|
forbidOnly: !!process.env.CI,
|
||||||
Loading…
x
Reference in New Issue
Block a user