Skip to content

Instantly share code, notes, and snippets.

@thyseus
Created September 5, 2018 06:29
Show Gist options
  • Save thyseus/7ce733ce015345d3738c115a30afa444 to your computer and use it in GitHub Desktop.
Save thyseus/7ce733ce015345d3738c115a30afa444 to your computer and use it in GitHub Desktop.
```php
class ReminderCest
{
public function _before(UnitTester $I)
{
}
public function _after(UnitTester $I)
{
}
public function testRunReminders(UnitTester $I)
{
$config = require(__DIR__ . '/../../config/console.php');
$application = new yii\console\Application($config);
$application->runAction('reminder/index');
}
}
@thyseus
Copy link
Author

thyseus commented Sep 5, 2018

class ReminderCest
{
public function _before(UnitTester $I)
{
}

public function _after(UnitTester $I)
{
}

public function testRunReminders(UnitTester $I)
{
    $config = require(__DIR__ . '/../../config/console.php');

    $db_test = require(__DIR__ . '/../../config/db_test.php');
    $config['components']['db'] = $db_test;

    $application = new yii\console\Application($config);
    $application->runAction('reminder/index');


}

}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment