From d4e790d3cf32c1ee406795fd188def39f8e83d50 Mon Sep 17 00:00:00 2001 From: Dan Brown Date: Sun, 5 Mar 2017 15:10:06 +0000 Subject: [PATCH] Added lang tests and update export text keys --- resources/lang/de/entities.php | 8 ++++---- resources/lang/en/entities.php | 8 ++++---- resources/lang/es/entities.php | 12 ++++++------ resources/lang/fr/entities.php | 8 ++++---- resources/lang/nl/entities.php | 8 ++++---- resources/lang/pt_BR/entities.php | 8 ++++---- resources/views/books/show.blade.php | 8 ++++---- resources/views/chapters/show.blade.php | 8 ++++---- resources/views/pages/show.blade.php | 8 ++++---- tests/LanguageTest.php | 21 +++++++++++++++++++++ 10 files changed, 59 insertions(+), 38 deletions(-) create mode 100644 tests/LanguageTest.php diff --git a/resources/lang/de/entities.php b/resources/lang/de/entities.php index ff590bb88..2859e4ec5 100644 --- a/resources/lang/de/entities.php +++ b/resources/lang/de/entities.php @@ -26,6 +26,10 @@ return [ 'no_pages_viewed' => 'Sie haben bisher keine Seiten angesehen.', 'no_pages_recently_created' => 'Sie haben bisher keine Seiten angelegt.', 'no_pages_recently_updated' => 'Sie haben bisher keine Seiten aktualisiert.', + 'export' => 'Exportieren', + 'export_html' => 'HTML-Datei', + 'export_pdf' => 'PDF-Datei', + 'export_text' => 'Text-Datei', /** * Permissions and restrictions @@ -160,10 +164,6 @@ return [ 'pages_revisions_preview' => 'Vorschau', 'pages_revisions_restore' => 'Zurück sichern', 'pages_revisions_none' => 'Diese Seite hat keine älteren Versionen.', - 'pages_export' => 'Exportieren', - 'pages_export_html' => 'HTML-Datei', - 'pages_export_pdf' => 'PDF-Datei', - 'pages_export_text' => 'Text-Datei', 'pages_copy_link' => 'Link kopieren', 'pages_permissions_active' => 'Seiten-Berechtigungen aktiv', 'pages_initial_revision' => 'Erste Veröffentlichung', diff --git a/resources/lang/en/entities.php b/resources/lang/en/entities.php index 109b6ee2a..f54134718 100644 --- a/resources/lang/en/entities.php +++ b/resources/lang/en/entities.php @@ -26,6 +26,10 @@ return [ 'no_pages_viewed' => 'You have not viewed any pages', 'no_pages_recently_created' => 'No pages have been recently created', 'no_pages_recently_updated' => 'No pages have been recently updated', + 'export' => 'Export', + 'export_html' => 'Contained Web File', + 'export_pdf' => 'PDF File', + 'export_text' => 'Plain Text File', /** * Permissions and restrictions @@ -161,10 +165,6 @@ return [ 'pages_revisions_preview' => 'Preview', 'pages_revisions_restore' => 'Restore', 'pages_revisions_none' => 'This page has no revisions', - 'pages_export' => 'Export', - 'pages_export_html' => 'Contained Web File', - 'pages_export_pdf' => 'PDF File', - 'pages_export_text' => 'Plain Text File', 'pages_copy_link' => 'Copy Link', 'pages_permissions_active' => 'Page Permissions Active', 'pages_initial_revision' => 'Initial publish', diff --git a/resources/lang/es/entities.php b/resources/lang/es/entities.php index d3a5ec4bd..14e952f1a 100644 --- a/resources/lang/es/entities.php +++ b/resources/lang/es/entities.php @@ -26,6 +26,10 @@ return [ 'no_pages_viewed' => 'Ud. no ha visto ninguna página', 'no_pages_recently_created' => 'Ninguna página ha sido creada recientemente', 'no_pages_recently_updated' => 'Ninguna página ha sido actualizada recientemente', + 'export' => 'Export', + 'export_html' => 'Contained Web File', + 'export_pdf' => 'PDF File', + 'export_text' => 'Plain Text File', /** * Permissions and restrictions @@ -127,7 +131,7 @@ return [ 'pages_delete_confirm' => 'Está ud. seguro de borrar esta página ?', 'pages_delete_draft_confirm' => 'Está ud. seguro de que desea borrar este borrador de página?', 'pages_editing_named' => 'Editando página :pageName', - 'pages_edit_toggle_header' => 'Toggle T�tulo', + 'pages_edit_toggle_header' => 'Toggle Título', 'pages_edit_save_draft' => 'Guardar borrador', 'pages_edit_draft' => 'Editar borrador de página', 'pages_editing_draft' => 'Editando borrador', @@ -139,7 +143,7 @@ return [ 'pages_edit_enter_changelog_desc' => 'Introduzca una breve descripción de los cambios que ha realizado', 'pages_edit_enter_changelog' => 'Entrar en Changelog', 'pages_save' => 'Guardar página', - 'pages_title' => 'T�tulo de página', + 'pages_title' => 'Título de página', 'pages_name' => 'Nombre de página', 'pages_md_editor' => 'Editor', 'pages_md_preview' => 'Preview', @@ -161,10 +165,6 @@ return [ 'pages_revisions_preview' => 'Preview', 'pages_revisions_restore' => 'Restore', 'pages_revisions_none' => 'This page has no revisions', - 'pages_export' => 'Export', - 'pages_export_html' => 'Contained Web File', - 'pages_export_pdf' => 'PDF File', - 'pages_export_text' => 'Plain Text File', 'pages_copy_link' => 'Copy Link', 'pages_permissions_active' => 'Page Permissions Active', 'pages_initial_revision' => 'Initial publish', diff --git a/resources/lang/fr/entities.php b/resources/lang/fr/entities.php index 941259f80..cfd206b91 100644 --- a/resources/lang/fr/entities.php +++ b/resources/lang/fr/entities.php @@ -26,6 +26,10 @@ return [ 'no_pages_viewed' => 'Vous n\'avez rien visité récemment', 'no_pages_recently_created' => 'Aucune page créée récemment', 'no_pages_recently_updated' => 'Aucune page mise à jour récemment', + 'export' => 'Exporter', + 'export_html' => 'Fichiers web', + 'export_pdf' => 'Fichier PDF', + 'export_text' => 'Document texte', /** * Permissions and restrictions @@ -160,10 +164,6 @@ return [ 'pages_revisions_preview' => 'Prévisualisation', 'pages_revisions_restore' => 'Restaurer', 'pages_revisions_none' => 'Cette page n\'a aucune révision', - 'pages_export' => 'Exporter', - 'pages_export_html' => 'Fichiers web', - 'pages_export_pdf' => 'Fichier PDF', - 'pages_export_text' => 'Document texte', 'pages_copy_link' => 'Copier le lien', 'pages_permissions_active' => 'Permissions de page actives', 'pages_initial_revision' => 'Publication initiale', diff --git a/resources/lang/nl/entities.php b/resources/lang/nl/entities.php index 46e69549b..610116c8b 100644 --- a/resources/lang/nl/entities.php +++ b/resources/lang/nl/entities.php @@ -26,6 +26,10 @@ return [ 'no_pages_viewed' => 'Je hebt nog niets bekeken', 'no_pages_recently_created' => 'Er zijn geen recent aangemaakte pagina\'s', 'no_pages_recently_updated' => 'Er zijn geen recente wijzigingen', + 'export' => 'Exporteren', + 'export_html' => 'Contained Web File', + 'export_pdf' => 'PDF File', + 'export_text' => 'Plain Text File', /** * Permissions and restrictions @@ -161,10 +165,6 @@ return [ 'pages_revisions_preview' => 'Preview', 'pages_revisions_restore' => 'Herstellen', 'pages_revisions_none' => 'Deze pagina heeft geen revisies', - 'pages_export' => 'Exporteren', - 'pages_export_html' => 'Contained Web File', - 'pages_export_pdf' => 'PDF File', - 'pages_export_text' => 'Plain Text File', 'pages_copy_link' => 'Link Kopiëren', 'pages_permissions_active' => 'Pagina Permissies Actief', 'pages_initial_revision' => 'Eerste publicatie', diff --git a/resources/lang/pt_BR/entities.php b/resources/lang/pt_BR/entities.php index a6e670353..922342424 100644 --- a/resources/lang/pt_BR/entities.php +++ b/resources/lang/pt_BR/entities.php @@ -26,6 +26,10 @@ return [ 'no_pages_viewed' => 'Você não visualizou nenhuma página', 'no_pages_recently_created' => 'Nenhuma página recentemente criada', 'no_pages_recently_updated' => 'Nenhuma página recentemente atualizada', + 'export' => 'Exportar', + 'export_html' => 'Arquivo Web Contained', + 'export_pdf' => 'Arquivo PDF', + 'export_text' => 'Arquivo Texto', /** * Permissions and restrictions @@ -161,10 +165,6 @@ return [ 'pages_revisions_preview' => 'Preview', 'pages_revisions_restore' => 'Restaurar', 'pages_revisions_none' => 'Essa página não tem revisões', - 'pages_export' => 'Exportar', - 'pages_export_html' => 'Arquivo Web Contained', - 'pages_export_pdf' => 'Arquivo PDF', - 'pages_export_text' => 'Arquivo Texto', 'pages_copy_link' => 'Copia Link', 'pages_permissions_active' => 'Permissões de Página Ativas', 'pages_initial_revision' => 'Publicação Inicial', diff --git a/resources/views/books/show.blade.php b/resources/views/books/show.blade.php index 99ffe80e1..f5e08b2f6 100644 --- a/resources/views/books/show.blade.php +++ b/resources/views/books/show.blade.php @@ -11,11 +11,11 @@
-
{{ trans('entities.pages_export') }}
+
{{ trans('entities.export') }}
@if(userCan('page-create', $book)) diff --git a/resources/views/chapters/show.blade.php b/resources/views/chapters/show.blade.php index 47a1d9ddf..28c34eef2 100644 --- a/resources/views/chapters/show.blade.php +++ b/resources/views/chapters/show.blade.php @@ -11,11 +11,11 @@
-
{{ trans('entities.pages_export') }}
+
{{ trans('entities.export') }}
@if(userCan('page-create', $chapter)) diff --git a/resources/views/pages/show.blade.php b/resources/views/pages/show.blade.php index fd6cebf41..6462225ea 100644 --- a/resources/views/pages/show.blade.php +++ b/resources/views/pages/show.blade.php @@ -11,11 +11,11 @@
-
{{ trans('entities.pages_export') }}
+
{{ trans('entities.export') }}
@if(userCan('page-update', $page)) diff --git a/tests/LanguageTest.php b/tests/LanguageTest.php new file mode 100644 index 000000000..ed5ee7dee --- /dev/null +++ b/tests/LanguageTest.php @@ -0,0 +1,21 @@ +asEditor(); + foreach ($langs as $lang) { + setting()->putUser($this->getEditor(), 'language', $lang); + $transResp = $this->get('/translations'); + foreach ($visibleKeys as $key) { + $transResp->assertSee($key); + } + } + } + +} \ No newline at end of file