> ## Documentation Index
> Fetch the complete documentation index at: https://alphaconsultings.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Scenarios

> How scenario generation, scenario seeders, and demo flows are tested for SQL, Mongo, and test-mode surfaces.

# Scenarios

Scenarios are coordinated artifact and runtime flows. They are heavier than single-model tests and should be used when you need end-to-end proof.

## What scenarios cover

* coordinated model generation
* services and controllers generated together
* migration generation
* factory generation
* seeders
* demo flows

## Typical commands

```bash theme={null}
eloquent make:scenario blog --test --controllers --services --run --force
eloquent demo:scenario --test --random
eloquent make:scenario --test --mongo --run
```

## When to use scenario tests

* generated artifact sets changed together
* relations or preset flows changed
* SQL and Mongo parity must be validated
* demo output and scenario seed paths changed

## Scenario test layers

* generator integration tests
* scenario lifecycle integration tests
* runtime scenario persistence tests
* generated REST API matrix tests over SQL drivers
* demo and factory-status validation
* tarball smoke for real-package behavior

## Real REST API matrix

For a real-time validation pass, generate the blog scenario with controllers and services, then bind the generated controllers into an Express app and exercise HTTP CRUD.

Execution order:

1. PostgreSQL
2. MySQL
3. SQLite

Typical flow:

```bash theme={null}
eloquent make:scenario blog --test --controllers --services --force
eloquent make:migration --all --test
eloquent migrate:run --test
eloquent db:seed --test --class BlogScenarioSeeder
```

REST routes exercised in the SQL matrix:

* `GET /users`
* `POST /users`
* `GET /users/:id`
* `PUT /users/:id`
* `GET /posts`
* `POST /posts`
* `GET /posts/:id`
* `PUT /posts/:id`
* `DELETE /posts/:id`

## Related pages

* [Advanced Integration / Real Backend Harness](./real-backend-harness)
* [Factories and seeds](./factories-seeds)
* [CLI and pack smoke](./cli-pack-smoke)
* [Common scenarios](../getting-started/common-scenarios)
