You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(biometric): Face ID / Touch ID / fingerprint testing (v0.9.7) (#110)
New ProbeScript steps and matching annotation DSL classes for driving
biometric auth flows on iOS Simulator and Android emulator without real
hardware. Skipped on physical devices with a warning (same pattern as
set location, allow permission, and other simulator-only ops).
Parser
2 new keywords (TOKEN_BIOMETRIC, TOKEN_ENROLL), 3 new ActionVerb
constants (VerbEnrollBiometric, VerbBiometricMatch,
VerbBiometricNoMatch), 2 new dispatch cases in parseStep, parseBiometric
and parseEnrollBiometric helpers. 3 new parser_test.go tests covering
every form.
Runner
EnrollBiometric, BiometricMatch, BiometricNoMatch methods on
DeviceContext. iOS uses xcrun simctl spawn booted notifyutil -p
com.apple.BiometricKit_Sim.faceCapture.match / .no-match (and the
fingerTouch.* equivalents, so the same step works on Face ID AND Touch
ID devices). Android uses adb -s <serial> emu finger touch <id>
where id=1 is matching (must be pre-enrolled) and id=9999 is no-match.
Physical devices skip with a warning, same pattern as SetLocation.
Dispatch cases in Executor.runAction; human-readable strings in
stepDescription so verbose runner output reads naturally.
Annotation DSL
3 new const Step classes — EnrollBiometric, BiometricMatch,
BiometricNoMatch — added to probe_annotation/lib/src/steps.dart.
Added to the const-constructibility test. Comprehensive doc comments
document the iOS/Android command paths and the physical-device skip.
Emitter
3 new cases in probe_gen/lib/src/probe_emitter.dart that produce
'enroll biometric', 'biometric match', 'biometric no match' lines.
New biometric_auth fixture+golden pair covering happy path (match
unlocks Dashboard) and unhappy path (no-match shows Authentication
failed). Cross-language golden_integration_test auto-picks it up.
Tests (strict)
go test ./... 16/16 packages pass
staticcheck ./... zero issues
parser_test.go 3 new biometric tests pass
probe_annotation dart test 3/3 const tests pass
probe_gen dart test 12/12 builder tests pass (was 11; +biometric_auth)
GoldenIntegration Go test 11/11 fixtures parse cleanly
Astro npm run build 37 pages built clean
Docs
website/src/content/docs/probescript/syntax.md new Biometric section
website/src/content/docs/probescript/annotations.md new Biometric subsection + DSL table entry
docs/wiki/Annotations.md step DSL table updated
README.md v0.9.7 callout added
CHANGELOG.md (root) [0.9.7] entry
probe_agent/CHANGELOG.md version-only bump
probe_annotation/CHANGELOG.md feature entry
probe_gen/CHANGELOG.md feature entry
vscode/package.json, docs/wiki/Home.md, mcp.md version refs bumped
Trade-offs (per user acknowledgement)
Real Face ID and Touch ID require an actual face or finger —
these steps are simulator/emulator only. Tests should target
a simulator/emulator in CI; physical iOS/Android device paths
skip with a warning so the test still completes.
Copy file name to clipboardExpand all lines: CHANGELOG.md
+12Lines changed: 12 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,6 +6,18 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
6
6
7
7
## [Unreleased]
8
8
9
+
## [0.9.7] - 2026-05-12
10
+
11
+
### Added
12
+
-**Biometric authentication testing** — three new ProbeScript steps that drive Face ID / Touch ID / fingerprint flows on iOS Simulator and Android emulator without real hardware. Skipped on physical devices with a warning (same pattern as `set location` and other simulator-only ops).
13
+
-`enroll biometric` — marks the simulator/emulator as having an enrolled face or finger. iOS posts the `com.apple.BiometricKit.enrollmentChanged` Darwin notification via `xcrun simctl spawn booted notifyutil`. Android requires the fingerprint to be pre-enrolled in Settings.
14
+
-`biometric match` — simulates a successful capture, satisfying any pending biometric prompt. iOS posts `*_Sim.faceCapture.match` AND `*_Sim.fingerTouch.match` so the same step works on Face ID and Touch ID devices. Android runs `adb -s <serial> emu finger touch 1`.
15
+
-`biometric no match` — simulates a failed capture so the app's "authentication failed" path can be tested. iOS posts the `.no-match` variants; Android runs `adb emu finger touch 9999` (an unregistered id).
16
+
-**Annotation DSL**: matching `EnrollBiometric()`, `BiometricMatch()`, `BiometricNoMatch()` const Step classes in `flutter_probe_annotation`, with a new `biometric_auth` golden fixture in `flutter_probe_gen/test/fixtures/` that round-trips through the Go parser via the cross-language integration test.
17
+
-**Parser**: 2 new tokens (`TOKEN_BIOMETRIC`, `TOKEN_ENROLL`), 3 new `ActionVerb` constants, 2 new parser dispatch cases. 3 new unit tests in `parser_test.go`.
18
+
-**Runner**: `EnrollBiometric` / `BiometricMatch` / `BiometricNoMatch` methods on `DeviceContext`, dispatch cases in `Executor.runAction`, and human-readable strings in `stepDescription`.
19
+
-**Docs**: new section in [annotations.md](https://flutterprobe.dev/probescript/annotations/#biometric-authentication-v097) and [syntax.md](https://flutterprobe.dev/probescript/syntax/#biometric-authentication) on the website. Per-package CHANGELOGs updated.
Copy file name to clipboardExpand all lines: README.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -417,6 +417,8 @@ Test definitions are now type-checked by `flutter analyze` — a misspelt step n
417
417
418
418
**v0.9.6** completes the annotation surface: full composite-test DSL (`@ProbeCompositeTest`, `Device`, `OnDevice`, `Sync`), id/selector-based `See`/`DontSee`, `WaitUntil.idAppears`, and composable `state` + `containing` + `matching` assertions. Plus fixes for two emitter bugs (`Mock` paths and `See` suffix dropping).
419
419
420
+
**v0.9.7** adds **biometric authentication testing** — `enroll biometric`, `biometric match`, `biometric no match` steps (and matching `EnrollBiometric()` / `BiometricMatch()` / `BiometricNoMatch()` annotation classes) drive Face ID / Touch ID / fingerprint flows on iOS Simulator and Android emulator. Skipped on physical devices.
421
+
420
422
Full reference: [flutterprobe.dev/probescript/annotations](https://flutterprobe.dev/probescript/annotations/) (or [`docs/wiki/Annotations.md`](docs/wiki/Annotations.md) on GitHub).
0 commit comments