diff options
| author | Valentin Popov <valentin@popov.link> | 2026-06-22 12:12:27 +0300 |
|---|---|---|
| committer | Valentin Popov <valentin@popov.link> | 2026-06-22 12:13:32 +0300 |
| commit | d0bdbaa1ed76dfbf3211bb43eee48c49cc4fd448 (patch) | |
| tree | a0bd35c3940be62a5b5de1acc2366af377ffd181 /crates/fparkan-test-support | |
| parent | 7416fdc7e9a48837fff5056e6dc8d0774e90964b (diff) | |
| download | fparkan-d0bdbaa1ed76dfbf3211bb43eee48c49cc4fd448.tar.xz fparkan-d0bdbaa1ed76dfbf3211bb43eee48c49cc4fd448.zip | |
feat: implement FParkan architecture foundation
Add the modular fparkan workspace, domain crates, adapters, apps, xtask policy/CI, acceptance evidence, and licensed corpus gates for the macOS-focused roadmap foundation.
Diffstat (limited to 'crates/fparkan-test-support')
| -rw-r--r-- | crates/fparkan-test-support/Cargo.toml | 12 | ||||
| -rw-r--r-- | crates/fparkan-test-support/src/lib.rs | 25 |
2 files changed, 37 insertions, 0 deletions
diff --git a/crates/fparkan-test-support/Cargo.toml b/crates/fparkan-test-support/Cargo.toml new file mode 100644 index 0000000..56a079f --- /dev/null +++ b/crates/fparkan-test-support/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "fparkan-test-support" +version.workspace = true +edition.workspace = true +license.workspace = true +repository.workspace = true + +[dependencies] +fparkan-render = { path = "../fparkan-render" } + +[lints] +workspace = true diff --git a/crates/fparkan-test-support/src/lib.rs b/crates/fparkan-test-support/src/lib.rs new file mode 100644 index 0000000..cb4f552 --- /dev/null +++ b/crates/fparkan-test-support/src/lib.rs @@ -0,0 +1,25 @@ +#![forbid(unsafe_code)] +//! Dev-only synthetic builders and fake ports. + +use fparkan_render::{FrameOutput, RenderBackend, RenderCommandList, RenderError}; + +/// Fake clock. +#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)] +pub struct FakeClock { + /// Current tick. + pub tick: u64, +} + +/// Recording backend. +#[derive(Clone, Debug, Default)] +pub struct RecordingRenderBackend { + /// Recorded command lists. + pub captures: Vec<RenderCommandList>, +} + +impl RenderBackend for RecordingRenderBackend { + fn execute(&mut self, commands: &RenderCommandList) -> Result<FrameOutput, RenderError> { + self.captures.push(commands.clone()); + Ok(FrameOutput) + } +} |
