/**
 * Base class for test entity builders. Holds default props and exposes a
 * `build()` for one entity and `buildMany(count)` for a list. Subclasses
 * override `build()` and add chainable `withXxx(...)` methods.
 *
 * ```ts
 * class ReviewRequestBuilder extends EntityBuilder<ReviewRequestProps, ReviewRequest> {
 *   build(): ReviewRequest { return new ReviewRequest(this.props); }
 *   withScore(score: number): this { this.props.score = score; return this; }
 * }
 * ```
 *
 * Complements `src/tests/factories/` for cases where a fluent builder is more
 * ergonomic than a plain factory function.
 */
export class EntityBuilder {
    props;
    constructor(defaultProps) {
        this.props = { ...defaultProps };
    }
    buildMany(count) {
        return Array.from({ length: count }, () => this.build());
    }
}
//# sourceMappingURL=entityBuilder.js.map