Skip to content

Commit

Permalink
Regenerated documentation from source
Browse files Browse the repository at this point in the history
  • Loading branch information
Naktibalda committed Nov 13, 2019
1 parent 9123b20 commit bbeb69d
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions documentation.md
Expand Up @@ -28,8 +28,23 @@ modules:

This will use static method of `MyDb::createEntityManager()` to establish the Entity Manager.

By default, the module will wrap everything into a transaction for each test and roll it back afterwards. By doing this
tests will run much faster and will be isolated from each other.
By default, the module will wrap everything into a transaction for each test and roll it back afterwards
(this is controlled by the `cleanup` setting).
By doing this, tests will run much faster and will be isolated from each other.

To use the Doctrine2 Module in acceptance tests, set up your `acceptance.suite.yml` like this:

```yaml
modules:
enabled:
- Symfony:
part: SERVICES
- Doctrine2:
depends: Symfony
``

You cannot use `cleanup: true` in an acceptance test, since Codeception and your app (i.e. browser) are using two
different connections to the database, so Codeception can't wrap changes made by the app into a transaction.

## Status

Expand Down

0 comments on commit bbeb69d

Please sign in to comment.