ci(raft): dedicated mandatory raft e2e job; no silent skips under CI
This commit is contained in:
@@ -61,6 +61,28 @@ jobs:
|
||||
done
|
||||
echo "--- Done ---"
|
||||
|
||||
raft-e2e:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Setup Nim
|
||||
uses: jiro4989/setup-nim-action@v1
|
||||
with:
|
||||
nim-version: '2.2.10'
|
||||
- name: Install system dependencies
|
||||
run: sudo apt-get update -qq && sudo apt-get install -y -qq libssl-dev libpcre3-dev openssl ca-certificates
|
||||
- name: Install Nim dependencies
|
||||
run: nimble install --depsOnly -y
|
||||
- name: Build server
|
||||
run: nim c -d:ssl -o:build/baradadb src/baradadb.nim
|
||||
- name: Raft e2e suites
|
||||
env:
|
||||
CI: "true"
|
||||
run: |
|
||||
nim c -d:ssl --threads:on --path:src -r tests/raft_e2e_test.nim
|
||||
nim c -d:ssl --threads:on --path:src -r tests/raft_writes_e2e_test.nim
|
||||
nim c -d:ssl --threads:on --path:src -r tests/raft_failover_load_e2e_test.nim
|
||||
|
||||
verify:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
||||
@@ -208,6 +208,10 @@ proc runClusterScenario() =
|
||||
suite "Raft E2E cluster":
|
||||
test "3-node election and failover":
|
||||
if not fileExists(BinaryPath):
|
||||
if getEnv("CI").len > 0:
|
||||
echo "[FAIL] ", BinaryPath, " missing under CI — build step broken?"
|
||||
fail()
|
||||
else:
|
||||
echo "[SKIP] ", BinaryPath, " missing — run `nimble test` (builds the server first)"
|
||||
skip()
|
||||
else:
|
||||
|
||||
@@ -425,6 +425,10 @@ proc runFailoverLoadScenario() =
|
||||
suite "Raft failover under load E2E":
|
||||
test "committed writes survive a leader kill under sustained write load":
|
||||
if not fileExists(BinaryPath):
|
||||
if getEnv("CI").len > 0:
|
||||
echo "[FAIL] ", BinaryPath, " missing under CI — build step broken?"
|
||||
fail()
|
||||
else:
|
||||
echo "[SKIP] ", BinaryPath, " missing — run `nimble test` (builds the server first)"
|
||||
skip()
|
||||
else:
|
||||
|
||||
@@ -412,6 +412,10 @@ proc runWritesScenario() =
|
||||
suite "Raft replicated writes E2E":
|
||||
test "writes replicate, followers reject, failover resumes writes":
|
||||
if not fileExists(BinaryPath):
|
||||
if getEnv("CI").len > 0:
|
||||
echo "[FAIL] ", BinaryPath, " missing under CI — build step broken?"
|
||||
fail()
|
||||
else:
|
||||
echo "[SKIP] ", BinaryPath, " missing — run `nimble test` (builds the server first)"
|
||||
skip()
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user