Skip to content

Commit 6b7a070

Browse files
committed
run multiple times
1 parent 9aed1f4 commit 6b7a070

File tree

1 file changed

+92
-0
lines changed

1 file changed

+92
-0
lines changed
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
name: Flakiness Check
2+
3+
on:
4+
push:
5+
6+
jobs:
7+
CI:
8+
name: Flakiness Check
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- uses: actions/checkout@v4
13+
with:
14+
submodules: "recursive"
15+
16+
- uses: actions/setup-java@v4
17+
with:
18+
java-version: "17"
19+
distribution: "temurin"
20+
cache: maven
21+
22+
- name: Build QuestDB
23+
run: mvn clean package -f packages/browser-tests/questdb/pom.xml -DskipTests -P build-binaries
24+
25+
- name: Extract QuestDB
26+
run: tar -xzf packages/browser-tests/questdb/core/target/questdb-*-rt-linux-x86-64.tar.gz -C tmp/
27+
28+
- name: Create DB Root
29+
run: mkdir tmp/dbroot
30+
31+
- uses: actions/setup-node@v4
32+
with:
33+
node-version: "20"
34+
cache: "yarn"
35+
36+
- name: Install dependencies
37+
run: yarn install --immutable --immutable-cache
38+
39+
- name: Build @questdb/react-components
40+
run: yarn workspace @questdb/react-components run build
41+
42+
- name: Build @questdb/web-console
43+
run: yarn workspace @questdb/web-console run build
44+
45+
- name: Run bundle watcher on @questdb/web-console
46+
run: yarn workspace @questdb/web-console bundlewatch
47+
48+
- name: Start FE Server
49+
run: |
50+
node packages/web-console/serve-dist.js &
51+
sleep 2
52+
echo "FE Server started in background"
53+
- name: Start QuestDB, set auth credentials
54+
run: ./tmp/questdb-*-rt-linux-x86-64/bin/questdb.sh start -d ./tmp/dbroot
55+
env:
56+
QDB_DEV_MODE_ENABLED: "true"
57+
QDB_HTTP_USER: "admin"
58+
QDB_HTTP_PASSWORD: "quest"
59+
60+
- name: Run browser-tests test multiple times
61+
run: |
62+
for i in {1..20}; do
63+
echo "Running browser-tests iteration $i/20"
64+
yarn workspace browser-tests cypress run --spec 'cypress/integration/console/editor.spec.js'
65+
if [ $? -ne 0 ]; then
66+
echo "Test failed on iteration $i"
67+
exit 1
68+
fi
69+
echo "Iteration $i completed successfully"
70+
done
71+
- name: Print Log Files
72+
if: success() || failure()
73+
run: cat tmp/dbroot/log/*
74+
75+
- name: Save QuestDB log on test failure
76+
if: failure()
77+
uses: actions/upload-artifact@v4
78+
with:
79+
name: questdb-log
80+
path: tmp/dbroot/log/*
81+
82+
- name: Upload Cypress Screenshots
83+
if: success() || failure()
84+
uses: actions/upload-artifact@v4
85+
with:
86+
name: cypress-screenshots
87+
path: packages/browser-tests/cypress/screenshots
88+
if-no-files-found: ignore
89+
90+
- name: Stop QuestDB
91+
if: success() || failure()
92+
run: ./tmp/questdb-*-rt-linux-x86-64/bin/questdb.sh stop

0 commit comments

Comments
 (0)