@@ -45,4 +47,4 @@ $userlistParams['subadmingroups'] = array_flip($items);
inc('users/part.createuser')); ?>
inc('users/part.userlist', $userlistParams)); ?>
-
\ No newline at end of file
+
diff --git a/tests/data/l10n/cs.json b/tests/data/l10n/cs.json
new file mode 100644
index 0000000000000000000000000000000000000000..c86f41aa077e26f9d7830c75a1f462afb4fa81e2
--- /dev/null
+++ b/tests/data/l10n/cs.json
@@ -0,0 +1,6 @@
+{
+ "translations" : {
+ "_%n window_::_%n windows_" : ["%n okno", "%n okna", "%n oken"]
+ },
+ "pluralForm" : "nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;"
+}
diff --git a/tests/data/l10n/cs.php b/tests/data/l10n/cs.php
deleted file mode 100644
index de106ede026d346c31a0cce4896b16a0b28df471..0000000000000000000000000000000000000000
--- a/tests/data/l10n/cs.php
+++ /dev/null
@@ -1,5 +0,0 @@
- array("%n okno", "%n okna", "%n oken")
-);
-$PLURAL_FORMS = "nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;";
diff --git a/tests/data/l10n/de.json b/tests/data/l10n/de.json
new file mode 100644
index 0000000000000000000000000000000000000000..c2b6f34c08187fab80972e78801bb15436c671ee
--- /dev/null
+++ b/tests/data/l10n/de.json
@@ -0,0 +1,6 @@
+{
+ "translations" : {
+ "_%n file_::_%n files_": ["%n Datei", "%n Dateien"]
+ },
+ "pluralForm" : "nplurals=2; plural=(n != 1);"
+}
diff --git a/tests/data/l10n/de.php b/tests/data/l10n/de.php
deleted file mode 100644
index 93c9ab4209ed035f80aa0f6b6e72715f8128de28..0000000000000000000000000000000000000000
--- a/tests/data/l10n/de.php
+++ /dev/null
@@ -1,5 +0,0 @@
- array("%n Datei", "%n Dateien")
-);
-$PLURAL_FORMS = "nplurals=2; plural=(n != 1);";
diff --git a/tests/data/l10n/ru.json b/tests/data/l10n/ru.json
new file mode 100644
index 0000000000000000000000000000000000000000..177b14a6b20f2038b3c17b56af54add502802e9c
--- /dev/null
+++ b/tests/data/l10n/ru.json
@@ -0,0 +1,6 @@
+{
+ "translations" : {
+ "_%n file_::_%n files_" : ["%n файл", "%n файла", "%n файлов"]
+ },
+ "pluralForm" : "nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"
+}
diff --git a/tests/data/l10n/ru.php b/tests/data/l10n/ru.php
deleted file mode 100644
index b778e8d79af83c6b804a28b5624bc55bfa8b9f80..0000000000000000000000000000000000000000
--- a/tests/data/l10n/ru.php
+++ /dev/null
@@ -1,5 +0,0 @@
- array("%n файл", "%n файла", "%n файлов")
-);
-$PLURAL_FORMS = "nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);";
diff --git a/tests/lib/l10n.php b/tests/lib/l10n.php
index a97fa22f05c6939f2da636267a3517e1fbd3cf6e..df86fcfda81abf0cf752e27c88d2f92646afd5f3 100644
--- a/tests/lib/l10n.php
+++ b/tests/lib/l10n.php
@@ -10,7 +10,7 @@ class Test_L10n extends PHPUnit_Framework_TestCase {
public function testGermanPluralTranslations() {
$l = new OC_L10N('test');
- $transFile = OC::$SERVERROOT.'/tests/data/l10n/de.php';
+ $transFile = OC::$SERVERROOT.'/tests/data/l10n/de.json';
$l->load($transFile);
$this->assertEquals('1 Datei', (string)$l->n('%n file', '%n files', 1));
@@ -19,7 +19,7 @@ class Test_L10n extends PHPUnit_Framework_TestCase {
public function testRussianPluralTranslations() {
$l = new OC_L10N('test');
- $transFile = OC::$SERVERROOT.'/tests/data/l10n/ru.php';
+ $transFile = OC::$SERVERROOT.'/tests/data/l10n/ru.json';
$l->load($transFile);
$this->assertEquals('1 файл', (string)$l->n('%n file', '%n files', 1));
@@ -44,7 +44,7 @@ class Test_L10n extends PHPUnit_Framework_TestCase {
public function testCzechPluralTranslations() {
$l = new OC_L10N('test');
- $transFile = OC::$SERVERROOT.'/tests/data/l10n/cs.php';
+ $transFile = OC::$SERVERROOT.'/tests/data/l10n/cs.json';
$l->load($transFile);
$this->assertEquals('1 okno', (string)$l->n('%n window', '%n windows', 1));