.snapshot.zip that captures a
test exactly as it would run right now, with modules expanded, step caches
resolved, environment variables baked in, and the relevant project config
frozen. A snapshot can later be replayed in complete isolation with
momentic run --from-snapshot
— no local test files, modules, environment, or cache backend required.
<testId>.snapshot.zip. Folders are
expanded into the tests they contain, exactly like
momentic run.
What a snapshot contains
Each zip holds two entries:test.yaml— the resolved test: metadata plus the fully expandedResolvedStep[]lists (before/main/after steps) with every step cache inlined.metadata.json— readable fields (momenticVersion,schemaVersion,createdAt,relativeFilePath, environment name, base URL, and the frozen project config:browser,ai,advanced,retries).
Snapshots can only be replayed by the organization that created them, to
prevent accidental leakage of environment secrets.
Arguments
One or more test file paths or folders on the local machine to snapshot. Pass
multiple values separated by spaces. Folders are expanded into every test they
contain.
Common flags
Path to the Momentic configuration file. Defaults to
momentic.config.yaml in
the current directory.When using workspaces, load the project whose name
matches the filter.
Directory to write the
.snapshot.zip files to. Defaults to the current
directory.Skip all confirmation prompts. Enabled by default when
CI is set.Environment
Environment to resolve when capturing the snapshot. Overrides any environment
configured on the test itself. The resolved variables are frozen into the
snapshot.
Override the base URL resolved into the snapshot. Useful for capturing a
snapshot pointed at a specific deployment.
Caching
Resolve every step cache from scratch instead of reusing existing caches
before freezing them into the snapshot.