From f76a2a75ccb06143bfec0559707b8d67cf0a2111 Mon Sep 17 00:00:00 2001 From: meadsteve Date: Fri, 31 May 2013 12:56:35 +0100 Subject: [PATCH] Empty Email plugin and test committed. --- PHPCI/Plugin/Email.php | 46 ++++++++++++++++++++++++++ Tests/PHPCI/Plugin/Email.php | 64 ++++++++++++++++++++++++++++++++++++ 2 files changed, 110 insertions(+) create mode 100644 PHPCI/Plugin/Email.php create mode 100644 Tests/PHPCI/Plugin/Email.php diff --git a/PHPCI/Plugin/Email.php b/PHPCI/Plugin/Email.php new file mode 100644 index 00000000..6cff58f9 --- /dev/null +++ b/PHPCI/Plugin/Email.php @@ -0,0 +1,46 @@ + +* @package PHPCI +* @subpackage Plugins +*/ +class Email implements \PHPCI\Plugin +{ + + /** + * @var \PHPCI\Builder + */ + protected $phpci; + + /** + * @var array + */ + protected $options; + + public function __construct(\PHPCI\Builder $phpci, array $options = array()) + { + $this->phpci = $phpci; + $this->options = $options; + } + + /** + * Connects to MySQL and runs a specified set of queries. + */ + public function execute() + { + + return true; + } +} \ No newline at end of file diff --git a/Tests/PHPCI/Plugin/Email.php b/Tests/PHPCI/Plugin/Email.php new file mode 100644 index 00000000..f1e97ffe --- /dev/null +++ b/Tests/PHPCI/Plugin/Email.php @@ -0,0 +1,64 @@ +mockCiBuilder = $this->getMock( + '\PHPCI\Builder', + array(), + array(), + "mockBuilder", + false + ); + $this->mockCiBuilder->buildPath = "/"; + + $this->loadEmailPluginWithOptions(); + } + + protected function loadEmailPluginWithOptions($arrOptions = array()) + { + $this->testedEmailPlugin = new EmailPlugin( + $this->mockCiBuilder, + $arrOptions + ); + } + + /** + * @covers PHPUnit::execute + */ + public function testExecute_ReturnsTrueWithoutArgs() + { + $returnValue = $this->testedEmailPlugin->execute(); + $expectedReturn = true; + + $this->assertEquals($expectedReturn, $returnValue); + } +} \ No newline at end of file