summaryrefslogtreecommitdiffstats
path: root/test/unit/SparkPostTest.php
diff options
context:
space:
mode:
authornornholdj <nornholdj@gmail.com>2014-11-03 15:37:21 -0500
committernornholdj <nornholdj@gmail.com>2014-11-03 15:37:21 -0500
commit1d6fad1db52c968f7cb8f6a93d3c84ae1f2b2dd8 (patch)
treedb74b901de1e6aeed20263d69cd70e2d4506059b /test/unit/SparkPostTest.php
parent9e9b7ac550ab663b393e757483bd78858d96686d (diff)
downloadphp-sparkpost-1d6fad1db52c968f7cb8f6a93d3c84ae1f2b2dd8.zip
php-sparkpost-1d6fad1db52c968f7cb8f6a93d3c84ae1f2b2dd8.tar.gz
php-sparkpost-1d6fad1db52c968f7cb8f6a93d3c84ae1f2b2dd8.tar.bz2
MA-946 #time 1h reviewed and updated function docs and other comments
Diffstat (limited to 'test/unit/SparkPostTest.php')
-rw-r--r--test/unit/SparkPostTest.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/unit/SparkPostTest.php b/test/unit/SparkPostTest.php
index 218cb6e..b019a15 100644
--- a/test/unit/SparkPostTest.php
+++ b/test/unit/SparkPostTest.php
@@ -7,6 +7,7 @@ class SparkPostTest extends \PHPUnit_Framework_TestCase {
/**
* @desc Ensures that the configuration class is not instantiable.
+ * @covers SparkPost::__construct
*/
public function testConstructorCannotBeCalled() {
$class = new \ReflectionClass('\MessageSystems\SparkPost');
@@ -16,6 +17,7 @@ class SparkPostTest extends \PHPUnit_Framework_TestCase {
/**
* @desc Tests that an exception is thrown when a library tries to recieve the config and it has not yet been set.
* Since its a singleton this test must come before any setConfig tests.
+ * @covers SparkPost::getConfig
* @expectedException Exception
* @expectedExceptionMessage No configuration has been provided
*/
@@ -25,6 +27,7 @@ class SparkPostTest extends \PHPUnit_Framework_TestCase {
/**
* @desc Tests that the api key is set when setting the config
+ * @covers SparkPost::setConfig
* @expectedException Exception
* @expectedExceptionMessage You must provide an API key
*/
@@ -34,6 +37,7 @@ class SparkPostTest extends \PHPUnit_Framework_TestCase {
/**
* @desc Tests that the api key is set when setting the config and that its not empty
+ * @covers SparkPost::setConfig
* @expectedException Exception
* @expectedExceptionMessage You must provide an API key
*/
@@ -43,6 +47,7 @@ class SparkPostTest extends \PHPUnit_Framework_TestCase {
/**
* @desc Tests overridable values are set while invalid values are ignored
+ * @covers SparkPost::setConfig
*/
public function testSetConfigMultipleValuesAndGetConfig() {
SparkPost::setConfig(['key'=>'lala', 'version'=>'v8', 'port'=>1024, 'someOtherValue'=>'fakeValue']);