aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/DateTimeFormatterTest.php
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2016-10-29 09:39:22 +0200
committerGitHub <noreply@github.com>2016-10-29 09:39:22 +0200
commite48fa1c3370632b5f8a2dcdeeabda217f50b3539 (patch)
treefdc7176cffe1f6e0a306efe0ccce149584e7f896 /tests/lib/DateTimeFormatterTest.php
parent035890aeb1b6e540396fd3c81841b60ea6d76f94 (diff)
parenta78f6e95869272b2d5cf34bd3374a9208ae80870 (diff)
downloadnextcloud-server-e48fa1c3370632b5f8a2dcdeeabda217f50b3539.tar.gz
nextcloud-server-e48fa1c3370632b5f8a2dcdeeabda217f50b3539.zip
Merge pull request #1948 from nextcloud/move_away_lagacy_oc_l10n
Move away from legacy OC_L10N
Diffstat (limited to 'tests/lib/DateTimeFormatterTest.php')
-rw-r--r--tests/lib/DateTimeFormatterTest.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/lib/DateTimeFormatterTest.php b/tests/lib/DateTimeFormatterTest.php
index 0d185128e27..85884c9bfb4 100644
--- a/tests/lib/DateTimeFormatterTest.php
+++ b/tests/lib/DateTimeFormatterTest.php
@@ -34,7 +34,7 @@ class DateTimeFormatterTest extends TestCase {
protected function setUp() {
parent::setUp();
- $this->formatter = new \OC\DateTimeFormatter(new \DateTimeZone('UTC'), new \OC_L10N('lib', 'en'));
+ $this->formatter = new \OC\DateTimeFormatter(new \DateTimeZone('UTC'), \OC::$server->getL10N('lib', 'en'));
}
protected function getTimestampAgo($time, $seconds = 0, $minutes = 0, $hours = 0, $days = 0, $years = 0) {
@@ -43,7 +43,7 @@ class DateTimeFormatterTest extends TestCase {
public function formatTimeSpanData() {
$time = 1416916800; // Use a fixed timestamp so we don't switch days/years with the getTimestampAgo
- $deL10N = new \OC_L10N('lib', 'de');
+ $deL10N = \OC::$server->getL10N('lib', 'de');
return array(
array('seconds ago', $time, $time),
array('1 minute ago', $this->getTimestampAgo($time, 30, 1), $time),
@@ -81,7 +81,7 @@ class DateTimeFormatterTest extends TestCase {
public function formatDateSpanData() {
$time = 1416916800; // Use a fixed timestamp so we don't switch days/years with the getTimestampAgo
- $deL10N = new \OC_L10N('lib', 'de');
+ $deL10N = \OC::$server->getL10N('lib', 'de');
return array(
// Normal testing
array('today', $this->getTimestampAgo($time, 30, 15), $time),