diff --git a/tests/phpunit/classes/SwiftTest.class.php b/tests/phpunit/classes/SwiftTest.class.php new file mode 100644 index 0000000000..df6bd45546 --- /dev/null +++ b/tests/phpunit/classes/SwiftTest.class.php @@ -0,0 +1,25 @@ +registerPlugin($app['monolog']); + return $app; + } + + public function testSend() + { + $client = $this->createClient(); + $crawler = $client->request('POST', '/', array("somedata"=>"to_send")); + $this->assertEquals(1, $this->app['mailer.logger']->countMessages(), "Only one email sent"); + + $emails = $this->app['mailer.logger']->getMessages(); + $this->assertEquals("This is my subject", $emails[0]->getSubject(), "Subject is correct"); + } +}*/ \ No newline at end of file