`live-conformance/model-sink/cases.json`, written by `wai_model_policy_vectors sink gen` from fixed seeds and the committed integer vectors, which it names and never copies: the operator's policy and its successor (which drops one set), a key log whose second revision revokes a set by its digest, another under the listing of its one member and a sealed set's opened bytes, a device attestation, two configurations, five a sink must refuse to hold, decode cases over the committed vectors at their instants (permitted sets, a payload the decoder refuses, a set outside the class, a set for another capability, a capability that runs no set, the revoked sets, the successor's start, both ends of the span, an attestation that has lapsed), every object of a frame stream permitted and refused, gate cases over a page's WebNN paths and a sealed set, the run reports a sink signs and the operator's roll-up. Every outcome is stated by the generator, never copied from the check. - `tests/model_sink_corpus.rs` (feature `model_policy`): the file regenerates byte for byte, and the reference's check gives every configuration, gate, decode and frame case its outcome, every code native-sink §14 names refusing one. - `tests/model_sink.rs` (`sink_decode`, `ffi`): every case through the C interface, the GPU offered and on the CPU alone; decoded cases give the bytes of a decoder with no policy, refused ones no bytes and the code; the reports hold exactly the decodes stated; the roll-up's class lines are the corpus's, units aside; both periods' bundles verify (`wai_model_verify`). With `WAI_MODEL_SINK_OUT` the bundles are written for `wai model verify` and the second implementation. - The Swift package's `ModelPolicyTests` and the Kotlin library's `ModelPolicyTest` (host JVM, through the JNI layer) run the corpus through their wrappers; scripts/build-xcframework.sh stages it, and TestHost bundles it. - `wai-web`'s `model_gate` gives every gate case its outcome and names every set as the corpus does. - `live-conformance/model_sink_verify.py`, the second implementation, written from the texts and sharing no code with wai-rs, gives every case its outcome, verifies the bundles a test wrote (`--bundles`), and catches 12 of 12 mutated copies and 18 of 18 weakened verifiers. - CI: the conformance step `model-sink` (its unit tests, the corpus test, wai-web's tests and the independent verifier); wai-sink-android.yml's JVM job runs tests/model_sink.rs before the Kotlin tests and requires ModelPolicyTest to run; both sink workflows trigger on the corpus. Co-Authored-By: Claude Opus 5.5 <[email protected]>
8 lines
248 B
Text
8 lines
248 B
Text
/build/
|
|
/.build/
|
|
/.swiftpm/
|
|
/Tests/WaiSinkTests/Resources/vectors.json
|
|
/Tests/WaiSinkTests/Resources/int/
|
|
/Tests/WaiSinkTests/Resources/model/
|
|
/TestHost/WaiSinkTestHost.xcodeproj/project.xcworkspace/
|
|
/TestHost/WaiSinkTestHost.xcodeproj/xcuserdata/
|