Repository navigation
Drop smoke() scaffold; one shared chat fixture - #19
Merged
Merged
Conversation
`smoke()` was a `#[wasm_bindgen]` export from the start of the port ("the
playground's real surface lands here as the port progresses") — the port is
done, `Sim` is the surface, and nothing calls `smoke()`. Removing it also
lets `engine::chat` (the hand-built `chat` schema it needed) stop being
`pub(crate)` and stop shipping in the wasm.
The six test modules that each rebuilt a `chat`-ish `ProjectShape` now share
`src/fixtures.rs` (`#[cfg(test)]`, imported as `use crate::fixtures as
chat;`): `shape()` / `shape_with(fns, hash)` / `fn_shape()` / `proto()` /
`schema()` / `session()` / `engine()`. `behavior.rs` keeps its own —
it's a `Counter`/`P` schema, not chat.
128 lib tests pass (was 129 — minus the smoke test); `--no-default-features`
green; `smoke` no longer in the generated `.d.ts`.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
smoke()— goneIt was a
#[wasm_bindgen] pub fnfrom the very start of the port, doc'd"the playground's real surface lands here as the port progresses". The
port finished;
Simis the surface; nothing (playground or tutorial) callssmoke(). Removing it also letsengine::chat— the hand-builtchatProjectShapeit depended on — stop beingpub(crate), so the fixtureschema no longer compiles into the shipped wasm and
smokeleaves thegenerated
.d.ts.One chat fixture instead of six
engine.rs,facade.rs,framedecode.rs,record.rs,generic.rs,model.rs,session_codec.rseach hand-rolled a near-identicalchatProjectShape. They now sharesrc/fixtures.rs(#[cfg(test)]),imported as
use crate::fixtures as chat;:shape()/shape_with(fns, ir_hash)/fn_shape(name, i, oneway)proto()/schema()/session()/engine()/CONNbehavior.rskeeps its own builder — it's aCounter/ protocol-Pschema, not chat.
Checks
cargo test128 pass (was 129, minus the smoke test),--no-default-featuresgreen,
cargo fmtclean,smokeabsent from the built.d.ts. Net −130lines.