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
|
||||
ports:
|
||||
- 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:
|
||||
CASSANDRA_USER: admin
|
||||
CASSANDRA_PASSWORD: admin
|
||||
@ -23,7 +27,6 @@ jobs:
|
||||
env:
|
||||
MINIO_ROOT_USER: minioadmin
|
||||
MINIO_ROOT_PASSWORD: minioadmin
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
@ -43,12 +46,12 @@ jobs:
|
||||
run: bun run migrate
|
||||
|
||||
- name: Setup environment
|
||||
run: |
|
||||
cp .env.example .env
|
||||
sudo echo "127.0.0.1 localhost" | sudo tee -a /etc/hosts
|
||||
run: cp .env.example .env
|
||||
|
||||
- name: Run Playwright tests
|
||||
run: bun run test
|
||||
run: |
|
||||
bun run dev --host &
|
||||
bun run test
|
||||
env:
|
||||
NODE_ENV: testing
|
||||
|
||||
|
@ -19,17 +19,11 @@ export default defineConfig({
|
||||
testMatch: /(.+\.)?(test|spec)\.[jt]s/,
|
||||
},
|
||||
],
|
||||
retries: !process.env.CI ? 1 : 0,
|
||||
retries: process.env.CI ? 1 : 0,
|
||||
reporter: 'list',
|
||||
webServer: {
|
||||
command: 'npm run dev --host',
|
||||
port: 5173,
|
||||
// Reuses webserver only in non-ci enviroments
|
||||
reuseExistingServer: !process.env.CI,
|
||||
},
|
||||
workers: 1,
|
||||
use: {
|
||||
baseURL: 'http://127.0.0.1:5173',
|
||||
baseURL: 'http://localhost:5173',
|
||||
trace: 'on-first-retry',
|
||||
},
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user