# trait

Within a `factory` definition block, use the `trait` method to define named permutations of the factory.

The trait method takes a name (Symbol) and a block. Treat the block like you
would a [`factory`] definition block.

[`factory`]: factory.html

See [method_missing](method_missing.html) for a shorthand.
