Author: Fabien Potencier (fabien@symfony.com)
Inheritance: extends Symfony\Component\HttpKernel\DependencyInjection\Extension
 public function testSpool()
 {
     $container = new ContainerBuilder();
     $loader = new SwiftmailerExtension();
     $loader->load(array(array('spool' => array())), $container);
     $this->assertEquals('swiftmailer.transport.spool', (string) $container->getAlias('swiftmailer.transport'));
     $this->assertEquals('swiftmailer.transport.smtp', (string) $container->getAlias('swiftmailer.transport.real'));
 }
 public function testMailerLoad()
 {
     $container = new ContainerBuilder();
     $loader = new SwiftmailerExtension();
     $loader->mailerLoad(array(), $container);
     $this->assertEquals('Swift_Mailer', $container->getParameter('swiftmailer.class'), '->mailerLoad() loads the swiftmailer.xml file if not already loaded');
     $loader->mailerLoad(array('transport' => 'sendmail'), $container);
     $this->assertEquals('sendmail', $container->getParameter('swiftmailer.transport.name'), '->mailerLoad() overrides existing configuration options');
     $loader->mailerLoad(array(), $container);
     $this->assertEquals('sendmail', $container->getParameter('swiftmailer.transport.name'), '->mailerLoad() overrides existing configuration options');
 }