Spex.Testing (spex v0.1.0)

Copy Markdown View Source

Test helpers for preparing and manipulating Spex runtime state.

Summary

Functions

Inserts or updates a mock instance at a specific state for test setup.

Prepares after-suite hooks that export collected implementation models.

Types

opt()

@type opt() :: {:instance_manager, module()} | {:impl_models_dir, Path.t()}

Functions

mock_instance!(spec, instance_identifier, state, meta \\ nil)

Inserts or updates a mock instance at a specific state for test setup.

prepare_for_test_suite(opts \\ [])

@spec prepare_for_test_suite([opt()]) :: :ok

Prepares after-suite hooks that export collected implementation models.