ci: Finish setting up testing CI
This commit is contained in:
parent
db3afe4758
commit
d299eee2e1
15
.github/workflows/playwright.yml
vendored
15
.github/workflows/playwright.yml
vendored
@ -11,7 +11,11 @@ jobs:
|
|||||||
image: cassandra:latest
|
image: cassandra:latest
|
||||||
ports:
|
ports:
|
||||||
- 9042:9042
|
- 9042:9042
|
||||||
options: --health-cmd="nodetool status" --health-interval=10s --health-timeout=5s --health-retries=5
|
options: >-
|
||||||
|
--health-cmd="nodetool status"
|
||||||
|
--health-interval=10s
|
||||||
|
--health-timeout=5s
|
||||||
|
--health-retries=5
|
||||||
env:
|
env:
|
||||||
CASSANDRA_USER: admin
|
CASSANDRA_USER: admin
|
||||||
CASSANDRA_PASSWORD: admin
|
CASSANDRA_PASSWORD: admin
|
||||||
@ -23,7 +27,6 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
MINIO_ROOT_USER: minioadmin
|
MINIO_ROOT_USER: minioadmin
|
||||||
MINIO_ROOT_PASSWORD: minioadmin
|
MINIO_ROOT_PASSWORD: minioadmin
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@ -43,12 +46,12 @@ jobs:
|
|||||||
run: bun run migrate
|
run: bun run migrate
|
||||||
|
|
||||||
- name: Setup environment
|
- name: Setup environment
|
||||||
run: |
|
run: cp .env.example .env
|
||||||
cp .env.example .env
|
|
||||||
sudo echo "127.0.0.1 localhost" | sudo tee -a /etc/hosts
|
|
||||||
|
|
||||||
- name: Run Playwright tests
|
- name: Run Playwright tests
|
||||||
run: bun run test
|
run: |
|
||||||
|
bun run dev --host &
|
||||||
|
bun run test
|
||||||
env:
|
env:
|
||||||
NODE_ENV: testing
|
NODE_ENV: testing
|
||||||
|
|
||||||
|
@ -19,17 +19,11 @@ export default defineConfig({
|
|||||||
testMatch: /(.+\.)?(test|spec)\.[jt]s/,
|
testMatch: /(.+\.)?(test|spec)\.[jt]s/,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
retries: !process.env.CI ? 1 : 0,
|
retries: process.env.CI ? 1 : 0,
|
||||||
reporter: 'list',
|
reporter: 'list',
|
||||||
webServer: {
|
|
||||||
command: 'npm run dev --host',
|
|
||||||
port: 5173,
|
|
||||||
// Reuses webserver only in non-ci enviroments
|
|
||||||
reuseExistingServer: !process.env.CI,
|
|
||||||
},
|
|
||||||
workers: 1,
|
workers: 1,
|
||||||
use: {
|
use: {
|
||||||
baseURL: 'http://127.0.0.1:5173',
|
baseURL: 'http://localhost:5173',
|
||||||
trace: 'on-first-retry',
|
trace: 'on-first-retry',
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user