summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/BridgeTest.php17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/BridgeTest.php b/test/BridgeTest.php
index 7912327..cc094e6 100644
--- a/test/BridgeTest.php
+++ b/test/BridgeTest.php
@@ -129,6 +129,23 @@ class BridgeTest extends PHPUnit_Framework_TestCase {
}
/**
+ * @dataProvider providerUnregisterMessage
+ */
+ public function testUnregisterMessage($messageId, $expected, $ex) {
+ if ($ex) $this->setExpectedException($ex);
+ $bridge = new Bridge($this->db);
+ $this->assertEquals($expected, $bridge->unregisterMessage($messageId));
+ }
+
+ public function providerUnregisterMessage() {
+ return array(
+ array(null, null, 'Exception'),
+ array('<20100302094228.33F0310091@charybdis.ellipsis.cx>', true, null),
+ array('<10100302094228.33F0310091@charybdis.ellipsis.cx>', false, null)
+ );
+ }
+
+ /**
* @dataProvider providerGetDefaultForumId
*/
public function testGetDefaultForumId($list, $expected, $ex) {