• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

prisma-risk / tsoracle / 26211786498
95%

Build:
DEFAULT BRANCH: main
Ran 21 May 2026 07:27AM UTC
Jobs 1
Files 30
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 May 2026 07:24AM UTC coverage: 93.485% (+0.5%) from 92.945%
26211786498

push

github

web-flow
feat: add failpoint testing for driver-file and server paths (#22)

* feat: add failpoint testing for driver-file and server paths

Introduce fault-injection testing via the `fail` crate, with eight failpoint
sites across `tsoracle-driver-file` (write_record crash boundaries) and
`tsoracle-server` (leader-watch fence + service path). Each opting-in crate
gets a per-crate `failpoints` Cargo feature (off by default) and a tiny
`failpoint!` wrapper macro that expands to nothing without the feature, so
release builds physically cannot contain failpoint code.

Sites and the invariants they exercise:

- `file_driver::before_write`, `::after_tmp_fsync_before_rename`,
  `::after_rename_before_dir_fsync`: assert that a crash at each persist-
  pipeline boundary leaves the canonical state file consistent on reopen.
- `file_driver::write_blocked`: generalizes the prior ad-hoc `SLOW_WRITE_HOOK`
  + `PERSIST_TEST_SERIAL` machinery, which is removed. The rewritten
  `load_is_not_blocked_by_in_flight_persist` test uses `fail::cfg_callback`
  for a deterministic entry handshake.
- `server::fence::after_load_before_persist`, `::after_persist_before_publish`:
  assert that a fault in the leader-watch task does not advance serving state,
  and observably preserves the durable-vs-serving split.
- `server::service::before_allocate`, `::extension_gate_held`: wiring tests
  for the request and extension-gate paths.

The closure form of the wrapper produces the enclosing function's exact
return type (`Result<(), FileDriverError>`, `Result<(), ServerError>`, etc.)
so failpoint returns are type-safe.

`openraft-toolkit` gains the feature/wrapper wiring but no sites yet; the
log-store failpoints were deferred to a follow-up because the openraft 0.10
`RaftLogStorage::append` test scaffolding warrants its own design pass.

`make test-failpoints` runs the suite. The existing CI `test` job already
runs `cargo test --workspace --all-features`, which activates the failpoint
features ... (continued)

38 of 38 new or added lines in 4 files covered. (100.0%)

2425 of 2594 relevant lines covered (93.48%)

205152.95 hits per line

Jobs
ID Job ID Ran Files Coverage
1 26211786498.1 21 May 2026 07:27AM UTC 30
93.48
GitHub Action Run
Source Files on build 26211786498
  • Tree
  • List 30
  • Changed 6
  • Source Changed 4
  • Coverage Changed 6
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #26211786498
  • 3c927418 on github
  • Prev Build on main (#26206844940)
  • Next Build on main (#26213504134)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc