aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/datetime/from_format_test.php28
-rw-r--r--tests/functional/registration_test.php5
2 files changed, 16 insertions, 17 deletions
diff --git a/tests/datetime/from_format_test.php b/tests/datetime/from_format_test.php
index f10402e8cb..8968619bb5 100644
--- a/tests/datetime/from_format_test.php
+++ b/tests/datetime/from_format_test.php
@@ -60,44 +60,44 @@ class phpbb_datetime_from_format_test extends phpbb_test_case
// If the current time is too close to the testing time,
// the relative time will use "x minutes ago" instead of "today ..."
// So we use 18:01 in the morning and 06:01 in the afternoon.
- $testing_time = date('H') <= 12 ? '18:01' : '06:01';
+ $testing_time = gmdate('H') <= 12 ? '18:01' : '06:01';
return array(
array(
- date('Y-m-d', time() + 2 * 86400) . ' ' . $testing_time, false,
- date('Y-m-d', time() + 2 * 86400) . ' ' . $testing_time,
+ gmdate('Y-m-d', time() + 2 * 86400) . ' ' . $testing_time, false,
+ gmdate('Y-m-d', time() + 2 * 86400) . ' ' . $testing_time,
),
array(
- date('Y-m-d', time() + 86400) . ' ' . $testing_time, false,
+ gmdate('Y-m-d', time() + 86400) . ' ' . $testing_time, false,
'Tomorrow ' . $testing_time,
),
array(
- date('Y-m-d', time() + 86400) . ' ' . $testing_time, true,
- date('Y-m-d', time() + 86400) . ' ' . $testing_time,
+ gmdate('Y-m-d', time() + 86400) . ' ' . $testing_time, true,
+ gmdate('Y-m-d', time() + 86400) . ' ' . $testing_time,
),
array(
- date('Y-m-d') . ' ' . $testing_time, false,
+ gmdate('Y-m-d') . ' ' . $testing_time, false,
'Today ' . $testing_time,
),
array(
- date('Y-m-d') . ' ' . $testing_time, true,
- date('Y-m-d') . ' ' . $testing_time,
+ gmdate('Y-m-d') . ' ' . $testing_time, true,
+ gmdate('Y-m-d') . ' ' . $testing_time,
),
array(
- date('Y-m-d', time() - 86400) . ' ' . $testing_time, false,
+ gmdate('Y-m-d', time() - 86400) . ' ' . $testing_time, false,
'Yesterday ' . $testing_time,
),
array(
- date('Y-m-d', time() - 86400) . ' ' . $testing_time, true,
- date('Y-m-d', time() - 86400) . ' ' . $testing_time,
+ gmdate('Y-m-d', time() - 86400) . ' ' . $testing_time, true,
+ gmdate('Y-m-d', time() - 86400) . ' ' . $testing_time,
),
array(
- date('Y-m-d', time() - 2 * 86400) . ' ' . $testing_time, false,
- date('Y-m-d', time() - 2 * 86400) . ' ' . $testing_time,
+ gmdate('Y-m-d', time() - 2 * 86400) . ' ' . $testing_time, false,
+ gmdate('Y-m-d', time() - 2 * 86400) . ' ' . $testing_time,
),
);
}
diff --git a/tests/functional/registration_test.php b/tests/functional/registration_test.php
index 26473c4fcd..690f4ae9f2 100644
--- a/tests/functional/registration_test.php
+++ b/tests/functional/registration_test.php
@@ -61,8 +61,7 @@ class phpbb_functional_registration_test extends phpbb_functional_test_case
{
$this->login('user-reg-test');
$crawler = self::request('GET', 'ucp.php?i=ucp_notifications&mode=notification_options&sid=' . $this->sid);
- $form_values = $crawler->selectButton('Submit')->form()->getValues();
- $this->assertEquals(1, $form_values['notification.type.post_notification.method.email']);
- $this->assertEquals(1, $form_values['notification.type.topic_notification.method.email']);
+ $this->assert_checkbox_is_checked($crawler, 'notification.type.post_notification.method.email');
+ $this->assert_checkbox_is_checked($crawler, 'notification.type.topic_notification.method.email');
}
}