Spex.ImplModelStore (spex v0.1.0)

Copy Markdown View Source

Loads and persists implementation models in .spex file format.

Summary

Functions

Loads all .spex models from a directory or a single file path.

Saves implementation models to the target directory.

Functions

load(impl_models_dir)

@spec load(Path.t()) ::
  {:ok, [Spex.ImplModel.t()]} | {:error, Spex.Errors.FileError.t()}

Loads all .spex models from a directory or a single file path.

save(impl_models, impl_models_dir)

@spec save([Spex.ImplModel.t()], Path.t()) ::
  :ok | {:error, [Spex.Errors.FileError.t()]}

Saves implementation models to the target directory.

Returns all write errors if one or more files fail to persist.