Skip to main content

Crate fabrique_derive

Crate fabrique_derive 

Source
Expand description

Procedural macros for generating factory and model code.

This crate provides two derive macros:

  • #[derive(Factory)] - Generates factory structs with optional fields for flexible object creation
  • #[derive(Model)] - Generates model implementations with database operations

Attribute Macros§

doctest
Creates an in-memory SQLite database with migrations for documentation examples.
test
Sets up a test database with migrations for the detected backend.

Derive Macros§

Factory
Derives a factory struct for the annotated type.
Model
Derives a Model implementation for the annotated struct.