PHPackages                             punktde/codeception-maildev - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. punktde/codeception-maildev

ActiveLibrary[Testing &amp; Quality](/categories/testing)

punktde/codeception-maildev
===========================

Provides a module and gherkin steps to access a maildev api for codeception testing

2.1.0(1y ago)016.6k↓15.2%3GPL-3.0-or-laterPHP

Since Jul 12Pushed 6mo ago6 watchersCompare

[ Source](https://github.com/punktDe/codeception-maildev)[ Packagist](https://packagist.org/packages/punktde/codeception-maildev)[ RSS](/packages/punktde-codeception-maildev/feed)WikiDiscussions main Synced yesterday

READMEChangelog (6)Dependencies (3)Versions (8)Used By (0)

punktde/codeception-maildev
===========================

[](#punktdecodeception-maildev)

Gherkin Steps and module functions to test using MailDev
--------------------------------------------------------

[](#gherkin-steps-and-module-functions-to-test-using-maildev)

### How to use

[](#how-to-use)

### Prequesits

[](#prequesits)

You have to have MailDev installed and have your application configured to send mails to maildev. See

#### Module

[](#module)

You have to add the `Webdriver` module to your config to use the `MailDev` module. Use the module `PunktDe\Codeception\MailDev\Module\MailDev` in your `codeception.yaml`. You can configure under which uri the maildev client is reachable (default is )

```
modules:
   enabled:
      - WebDriver:
        url: 'http://acceptance.dev.punkt.de/'
        browser: chrome
        restart: true
        window_size: 1920x2080
        capabilities:
          chromeOptions:
            args:
              - '--headless'
              - '--disable-gpu'
              - '--disable-dev-shm-usage'
              - '--no-sandbox'
      - PunktDe\Codeception\MailDev\Module\MailDev:
        base_uri: http://maildev.project
```

You can add authentication parameters to authenticate with the guzzle client when necessary. For futher details see

```
modules:
   enabled:
      - PunktDe\Codeception\MailDev\Module\MailDev:
        base_uri: http://maildev.project
        username: 'user'
        password: 'secret'
        authenticationType: 'basic'
```

#### Gherkin steps

[](#gherkin-steps)

Just add the trait `PunktDe\Codeception\MailDev\ActorTraits\MailDev` to your testing actor. Then you can use `*.feature` files to write your gherkin tests with the new steps.

##### Example actor

[](#example-actor)

```
