aboutsummaryrefslogtreecommitdiffstats
path: root/tests/notification/notification_test.php
diff options
context:
space:
mode:
authorNathaniel Guse <nathaniel.guse@gmail.com>2013-07-26 14:51:46 -0500
committerNathaniel Guse <nathaniel.guse@gmail.com>2013-07-26 14:51:46 -0500
commit4f0dd9a752c79004acdfbedce92234c6818b9765 (patch)
treecc3e3006f67d7c5ba63ef2e03691eb0752b632cb /tests/notification/notification_test.php
parent185d4e112e2f1d01364aad36eb540294fa7c953b (diff)
downloadforums-4f0dd9a752c79004acdfbedce92234c6818b9765.tar
forums-4f0dd9a752c79004acdfbedce92234c6818b9765.tar.gz
forums-4f0dd9a752c79004acdfbedce92234c6818b9765.tar.bz2
forums-4f0dd9a752c79004acdfbedce92234c6818b9765.tar.xz
forums-4f0dd9a752c79004acdfbedce92234c6818b9765.zip
[ticket/11744] Tables are not truncated in some dbms during tests
PHPBB3-11744
Diffstat (limited to 'tests/notification/notification_test.php')
-rw-r--r--tests/notification/notification_test.php16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/notification/notification_test.php b/tests/notification/notification_test.php
index 39073c2602..94453fe201 100644
--- a/tests/notification/notification_test.php
+++ b/tests/notification/notification_test.php
@@ -21,14 +21,14 @@ class phpbb_notification_test extends phpbb_tests_notification_base
public function test_get_notification_type_id()
{
// They should be inserted the first time
- $this->assertEquals(1, $this->notifications->get_notification_type_id('post'));
- $this->assertEquals(2, $this->notifications->get_notification_type_id('quote'));
- $this->assertEquals(3, $this->notifications->get_notification_type_id('test'));
+ $post_type_id = $this->notifications->get_notification_type_id('post');
+ $quote_type_id = $this->notifications->get_notification_type_id('quote');
+ $test_type_id = $this->notifications->get_notification_type_id('test');
$this->assertEquals(array(
- 'test' => 3,
- 'quote' => 2,
- 'post' => 1,
+ 'test' => $test_type_id,
+ 'quote' => $quote_type_id,
+ 'post' => $post_type_id,
),
$this->notifications->get_notification_type_ids(array(
'test',
@@ -36,11 +36,11 @@ class phpbb_notification_test extends phpbb_tests_notification_base
'post',
)
));
- $this->assertEquals(2, $this->notifications->get_notification_type_id('quote'));
+ $this->assertEquals($quote_type_id, $this->notifications->get_notification_type_id('quote'));
try
{
- $this->assertEquals(3, $this->notifications->get_notification_type_id('fail'));
+ $this->assertEquals(false, $this->notifications->get_notification_type_id('fail'));
$this->fail('Non-existent type should throw an exception');
}