Core and the app · crate
kinogaki-testkit
Kinogaki Studio's core testkit: toy packages written against the SDK alone, so core is tested with no real plugin.
- Repository
- Core and the app (kinogaki/studio-core)
- Folder
studio/core/testkit- Source
- 48 files, 11,992 lines
- Tests
- 0 files, 0 lines
What it is
Kinogaki Studio's core testkit: toy packages written against the SDK alone, so core is tested with no real plugin. Plugins use it as a dev-dependency only (tools/architecture).
| Package | Name | What it covers |
|---|---|---|
board (toy.board) | board | a context with every UI part: library, inspector, viewport layer (keys, holds, popovers, controls, overlay, and a live tool, Stretch, with its card, its drag, its heads-up value and its numeric bar), a level and its stacked list, a vocabulary, object rows (told when a board is first inspected), results; a user settings page whose rows show live state over a user value a creation reads; undoable slots; a pin the host's gizmo moves; a declared handle (Row's Spacing); a core network with a held edit and a multi-input |
blocks (toy.blocks) | blocks | a drawable data type with every facet (Displayable with tallies and boxes, ObjectPicking with templated branches' pieces, Look, Snappable, Tabular, Renderable as a TriangleSource); node types for every ValueKind, a box handle, a time-reading animatable number, a failing cook and a slow one, a Merge taking operands; tools, and a viewport layer whose live node a test sets |
files (toy.files) | files | a format (toy.format.blocks) that reads and writes .blocks files, and two toy image formats (images: .picture, written as a display shows an image, and .light, as linear light), whose reads of a file a test holds wait until it lets them go (held) |
looks (toy.looks, linked) | — | a format of materials, images and domes (toy.format.looks): a file's whole Shading networks and standard forms, textures on disk, embedded or packed in the file, a dome naming an image by key |
shapes (toy.shapes) | shapes | a headless toy kernel over the standard data types core registers: a Quad making polygons, a Line making curves, and a toy modelling tool over core's editing API on both its paths, an Extrude cooking and an Edit holding stored edits that save |
pictures (toy.pictures) | pictures | standard images: a Ramp making one over a data window of tiles, a Dab replacing one tile, both painted by core's 2D canvas; an Arranged node making a value painted as pieces under placements, with text |
handles (toy.handles, linked) | — | a node type and an object kind giving the handles a test declares; the kind a render prim written back through with_declared |
patches (toy.patches, linked) | — | a context with Point, Edge and Face levels that combine, a Piece level (connected pieces) and an All preset over core's standard Geometry (a Patch object's Grid), keeping its selection in an undoable slot and every hit the host hands it |
layers (toy.layers, linked) | — | a value drawn as ordered pieces (a Pile's Layers, a square a layer) whose viewport layer chooses which of them draw (Edited::pieces) |
ledger (toy.ledger, linked) | — | project settings alone: two values of the project's (a number and a path row) and Settings ▸ Project's section editing them |
planar (toy.planar, linked) | — | a B-rep mesher: planar faces of one loop as polygons, straight edges as polylines |
shading (test.shade, linked) | — | two toy engines' material nodes (a Paint, a Flat), each translating the other's |
stage (toy.stage, linked) | — | an engine and its Light kind (a render prim of a type it names), and core's Render Output for an engine, what core's render sync reads with no engine package |
tracer (toy.tracer, linked) | — | a render engine on the SDK alone: its own material nodes, a CPU ray caster on a thread of its own, lit by what its lights add up to, instances and motion, previews and display approximations, idle and cancel; made on a host's device with the crate's engine feature |
crates (toy.crates) | crates | a headless package (no UI part): a core network context, a listed node type with vector rows and an object kind opening into it, served by core's UI alone; a Pallet node holding a labels network of Label nodes inside it (Description::holding), and a Shelf holding one it reads (Reads::inside); the labels context adopting the Crate node; a networkless Rack kind with a value and published Materials |
fixtures builds the networks tests and latency workloads use, and kino is the .kino format suite's harness (round trips, comparisons, generated fixtures, damage), which core/project's tests and any plugin's run. render_output is core's Render Output kind, which a plugin's tests read a render output through.
Choosing packages. A host's tests ask for packages by name as --plugins does ("blocks,files", packages); toy names all of the testkit's. Render engines aren't the testkit's: tests that render with a real engine ask for it by its own name.
Depends on
| Crate | Repository | As | What it is |
|---|---|---|---|
kinogaki-color-service | Core and the app | normal | Studio's color service: the OpenColorIO config (lib-color's built-in ACES 2.0 CG config, or a file), the working space, and the viewer's display, view, look, exposure and gamma. |
kinogaki-cook | Core and the app | normal | Studio's core cooking engine, the same for every network kind (the owner's rule: the cooking DAG for nodes is core's). |
kinogaki-core-package | Core and the app | normal | Core's own SDK package (kinogaki.core): what Studio holds whatever plugins are installed. |
kinogaki-document | Core and the app | normal | Studio's document: the scene, a tree of objects under one root, and the core network each object of a kind naming a context holds. |
kinogaki-math | lib-math | normal | Kinogaki's vectors, points, matrices, quaternions and deterministic elementary functions. |
kinogaki-network | Core and the app | normal | Studio's core networks (design: core-owned networks; "Cooking DAG for nodes is studio core"). |
kinogaki-prism | lib-prism | normal | Prism documents for Kinogaki. |
kinogaki-project | Core and the app | normal | Studio's project files: a document as a Prism document. |
kinogaki-render-api | SDK | normal | Kinogaki's render interface: what a host (Studio) sends a render engine and what comes back, with no GPU or OS API. |
kinogaki-studio-api | SDK | normal | Kinogaki Studio's headless plugin API. |
kinogaki-studio-api-testing | SDK | normal | The SDK's test support (a dev-dependency only): assert_refused for admission tests, read_hostile for a format's tests of hostile files, format for its scratch folders and round trips, workers as a host installs them, with wgpu an ... |
kinogaki-studio-ui-api | SDK | normal | Kinogaki Studio's UI layer for plugins. |
kinogaki-studio-ui-api-testing | SDK | normal | The UI layer's test support (a dev-dependency only): headless fakes of the host's UI for plugin unit tests: RecordingUi and RecordingPainter record what a plugin asks to show and draw, and play back scripted user actions, with no window and no GPU ... |
kinogaki-viewport-api | SDK | normal | Kinogaki's viewport packet contract: what a data type hands Studio's viewport to draw, with no GPU or UI API. |
Third-party
None.
Used by
| Crate | Repository | As | What it is |
|---|---|---|---|
kinogaki-comp | Comp | tests | Comp as an SDK package (kinogaki.comp): what fills Studio's Comp context (kinogaki.core.comp, core declares it, inside a Render Output object). |
kinogaki-document | Core and the app | tests | Studio's document: the scene, a tree of objects under one root, and the core network each object of a kind naming a context holds. |
kinogaki-editor | Core and the app | tests | Kinogaki Studio's editor: the document and everything the window shows of it, as parts one frame borrows one by one. |
kinogaki-harness | Core and the app | normal | Studio's test harness: the real editor, its event routing and its background work, driven offscreen with only the packages a test names. |
kinogaki-image-pipeline | Core and the app | tests | ImagePipeline: what renders become on screen and in files. |
kinogaki-layout | Layout | tests | The Layout context: a page on the 2D canvas and the pieces arranged on it, images and text, back to front in the order their nodes run. |
kinogaki-mesh | Mesh | tests | The Mesh plugin: polygon modelling, Maya's and Houdini's toolset on core's editing API (plugins/mesh/PLAN.md holds the inventory and its groups). |
kinogaki-mesh-kernel | Mesh | tests | The Mesh kernel: the heavy, robustness-critical polygon algorithms, offered to every package as verbs (kernel). |
kinogaki-network | Core and the app | tests | Studio's core networks (design: core-owned networks; "Cooking DAG for nodes is studio core"). |
kinogaki-project | Core and the app | tests | Studio's project files: a document as a Prism document. |
kinogaki-scene | Core and the app | tests | Studio's scene: the document cooked object by object. |
kinogaki-spectre | Spectre | tests | Spectre, the spectral path tracer, as a Kinogaki Studio render plugin. |
kinogaki-workflows | Workflows | tests | Tests alone: tests/workflows drives what a person does across the plugins the app ships, through the real editor offscreen. |
Modules
blocksThe Blocks package (toy.blocks): a drawable data type (data), Blocks objects holding a core network of the Blocks context, its node types (nodes), and a UI part with tools (Add Block, Add Grid) for shelves, Tab's tools, marking menus, shortcuts ...266 linesblocks::dataBlocks: axis-aligned boxes, the testkit's drawable data type.703 linesblocks::nodesThe Blocks context's node types.610 linesboardA toy package written against the SDK alone, installed in test builds: a context with an inspector, a viewport layer, levels and a vocabulary with its library over session slots (its marks, a pin the host's transform gizmo moves, and a span its live tool ...647 linesboard::networkThe toy's network: a context whose networks are core's one node shape, so a board object holds a real core network that core creates, edits, cooks, undoes and saves.344 linesboard::settings(private)The toy's user settings: a user value and its page of the Settings window.67 linesboard::view(private)The board's viewport parts: Stretch, its live tool (its drags, wheel and card), the views' badges and a popup as panels, the pin's gizmo and the Gear (Hold, Reach), and what it draws (a ring at the pointer, the heads-up span).286 linescompA compiled context's package for core's Comp network (toy.comp, linked), so a host's image pipeline runs plans with no Comp plugin:165 linescratesThe crates package (toy.crates): headless, with no UI part.446 linesengineThe Stage's render engine made (stage::packagecarries it with this feature): the SDK'sRecordingEnginemade on any device (a no-op one will do), so a host's image pipeline is tested with no GPU.281 linesfilesThe Block Files package (toy.files): a format plugin reading and writing.blocksfiles, so File ▸ Import, Export and the File node have something to work with (and something to miss when it's off), and two toy image formats (images) for ...204 linesfixturesNetworks tests and latency workloads build, written through the SDK'sNetworkEditso any host (the editor's harness, the SDK's fake network) builds the same thing.49 lineshandlesA package whose handles the test declares (toy.handles), as Houdini's handle bindings are declared:packagemakes one for a list of handles, which both its node type and its object kind give.434 linesheldReads of the toy pictures held back (hold): a read of a held file waits until the test lets it go, as a slow file holds its reader, with no pipe on disk (Studio never reads one).121 linesimagesTwo toy image formats of the Block Files package, so core's image store and its final writes have files to read and write with no real image plugin:.picture(toy.format.picture), whose writer takes a display's code values as a PNG's does, and.light...217 lineskinoThe.kinoformat suite's harness (KINO-FORMAT-TESTS): round trips in every encoding, comparisons that name what differs, fixtures generated from the registry, values a file must keep exactly, a seeded generator and damage, projects of a size, and child ...97 lineskino::childRunning a test again as a child process: what a process can't undo (installing a package, its hash seeds, its thread budget) differs in the child.42 lineskino::compareComparing a project with what it read back as: the differences, each naming what differs (an object by name, a node by its type's id, so a generated fixture that fails says which type), and what its networks cook to.220 lineskino::exactValues a project must hold exactly, bit for bit: numbers at the edges of f64 and f32, and text that is long, non-ASCII or needs escaping in Prism text.77 lineskino::fixturesProjects generated from what is installed, so a new node type, object kind or parameter kind is in a fixture the moment it is installed, with no test to edit:288 lineskino::mutateDamage to a saved project, seeded: what a disk, a transfer, a hand edit or another program could do to a file.264 lineskino::rngA small seeded generator (SplitMix64): the same seed makes the same cases on every machine, so a failing seed reproduces.28 lineskino::scaleProjects of a size:nnodes as a user makes them (Blocks objects of ten nodes each, a Grid then a chain of Every nodes, under Parts), and a frozen grid of blocks (its kept outputs stored).52 lineskino::valuesValues other than a parameter's default, made from its kind alone, so a fixture generated from the registry sets every parameter of every type to something its file must hold.117 lineslayersThe layers package (toy.layers, linked): a value drawn as ordered pieces, as a print is drawn layer by layer.248 linesledgerThe ledger package (toy.ledger, linked): settings and nothing else.256 lineslooksThe Looks package (toy.looks): a toy format of materials, images and lights (toy.format.looks,.looks): what File ▸ Import adopts as a Material Library, its Image nodes and a dome, and what Export hands a writer.423 linespatchesThe patches package (toy.patches, linked): a context with selection levels over core's standard Geometry, as a modeling plugin has them.572 linespatches::extrudeThe patches' extrude drag: whilePatches::extruding, the host's gizmo drags the distance of the displayed Extrude node.131 linespatches::movesThe patches' moves: the host's gizmo drags the selected points (whilePatches::moves), soft withPatches::softand mirrored across x = 0 withPatches::symmetric.265 linespicturesA package of pictures (toy.pictures), core's standard images on no real plugin: a Ramp node, a Dab replacing one tile, and an Arranged node painted as pieces under placements, what core's 2D canvas shows.325 linesplanarThe planar package (toy.planar, linked): a toy B-rep mesher on the SDK alone, so B-reps show and export meshed with no B-rep kernel installed.173 linesshadingTwo toy engines bringing material nodes of their own (test.shade, linked):hereandthere, each with a Paint (a Red value) and a Flat (a Color), so a test sees a Material compile and reach an engine.144 linesshapesThe shapes package (toy.shapes): headless, a toy kernel over the standard data types core registers.261 linesshapes::attributed(private)The Attributed node (toy.shapes.attributed): a 2 × 2 grid carrying an attribute of every storage, width and meaning, and arrays, on every domain a polygons value has.219 linesshapes::copies(private)The Copies node (toy.shapes.copies): its Prototype at every point of its Points, as one standard Instances value placed by the points' instance attributes (kinogaki_geometry::placements): what Copy to Points and engines' instancing build on.52 linesshapes::extrudeThe toy modelling tool over core's editing API, on both of its paths: the Extrude node (toy.shapes.extrude) edits its input throughEditoras it cooks and core caches the result; the Edit node (toy.shapes.edit) holds its edits asStoredvalues ...468 linesshapes::kernelA toy kernel's verb: the shapes package offers it, and a consumer reaches it by its id alone.36 linesshapes::merge(private)The Merge node (toy.shapes.merge): its inputs in one value, through the SDK's one rule (gather), or any instances among them kept (Instances::gathered): a port of two types.55 linesstageA package of what a render is set up with (toy.stage, linked): an engine and its Light kind, as an engine's package declares them, so core's render sync is tested with no engine package.524 linestracerA toy render engine on the SDK alone (toy.tracer, linked): a small CPU ray caster on a thread of its own, written from the SDK's docs.209 linestracer::scene(private)The tracer's scene: the prims it was sent, what it built of each shape, and what it logged of each update.207 linestracer::shown(private)The tracer on a host's device (the crate'senginefeature): it renders on its own thread and publishes pixels, so it holds no image for the host to show, and a test reads its passes (pixel).37 linestracer::trace(private)One pass of rays through a scene: the first hit of each, and its color.338 linestracer::worker(private)Tracer: the engine and its thread.413 lines
Public types and traits
Re-exported from other crates
From kinogaki_core_package render_output
By module: 44 public types and traits in 23 modules
blocks BlocksBodyTools
blocks::data BlockBlocksBlocksTypeBlockTrianglesPicked
board BoardBoardBodyMarksPinProbeSpanStretchingToy
board::settings BoardSettings
crates RackBody
engine RecordedSent
handles GateTool
held Hold
images ToyImages
kino::compare Cooked
kino::fixtures SkippedVariant
kino::mutate Damaged
kino::rng Rng
layers Shown
ledger CountLedgerSpacingTemplate
looks Looks
patches PatchesProbe
patches::extrude Drag
pictures Arrangement
planar Planar
shapes::extrude Stored
tracer Rules
tracer::worker AppliedCountersTracer
Besides these, 145 public functions at module level.
