aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorVirtualTam <virtualtam+github@flibidi.net>2017-09-19 19:22:33 +0200
committerGitHub <noreply@github.com>2017-09-19 19:22:33 +0200
commit0cba184cf80423d990aba09a2a0a1f2b9c5882b7 (patch)
treeda0ea3e3401ffb3f89684fb6465ce0c13e11fb51
parent6aae4bd0a15575eb11b4774cfdcdad1c2a994fe0 (diff)
parentb5c33d702ac973e7bc1401e484c6b8799eea1e91 (diff)
downloadShaarli-0cba184cf80423d990aba09a2a0a1f2b9c5882b7.tar.gz
Shaarli-0cba184cf80423d990aba09a2a0a1f2b9c5882b7.tar.zst
Shaarli-0cba184cf80423d990aba09a2a0a1f2b9c5882b7.zip
Merge pull request #972 from virtualtam/travis/trusty
Travis: switch to Ubuntu Trusty build environment
-rw-r--r--.travis.yml9
-rw-r--r--tests/languages/de/UtilsDeTest.php12
-rw-r--r--tests/languages/en/UtilsEnTest.php12
-rw-r--r--tests/languages/fr/UtilsFrTest.php12
4 files changed, 20 insertions, 25 deletions
diff --git a/.travis.yml b/.travis.yml
index 26535ad3..b6b9bddf 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,12 +1,6 @@
1sudo: false 1sudo: false
2dist: precise 2dist: trusty
3language: php 3language: php
4addons:
5 apt:
6 packages:
7 - locales
8 - language-pack-de
9 - language-pack-fr
10cache: 4cache:
11 directories: 5 directories:
12 - $HOME/.composer/cache 6 - $HOME/.composer/cache
@@ -18,6 +12,7 @@ php:
18install: 12install:
19 - composer self-update 13 - composer self-update
20 - composer install --prefer-dist 14 - composer install --prefer-dist
15 - locale -a
21script: 16script:
22 - make clean 17 - make clean
23 - make check_permissions 18 - make check_permissions
diff --git a/tests/languages/de/UtilsDeTest.php b/tests/languages/de/UtilsDeTest.php
index 6c9c9adc..4569c923 100644
--- a/tests/languages/de/UtilsDeTest.php
+++ b/tests/languages/de/UtilsDeTest.php
@@ -81,12 +81,12 @@ class UtilsDeTest extends UtilsTest
81 } 81 }
82 82
83 /** 83 /**
84 * Test autoLocale with multiples value, the second one is valid 84 * Test autoLocale with multiples value, the second one is available
85 */ 85 */
86 public function testAutoLocaleMultipleSecondValid() 86 public function testAutoLocaleMultipleSecondAvailable()
87 { 87 {
88 $current = setlocale(LC_ALL, 0); 88 $current = setlocale(LC_ALL, 0);
89 $header = 'pt_BR,fr-fr'; 89 $header = 'mag_IN,fr-fr';
90 autoLocale($header); 90 autoLocale($header);
91 $this->assertEquals('fr_FR.utf8', setlocale(LC_ALL, 0)); 91 $this->assertEquals('fr_FR.utf8', setlocale(LC_ALL, 0));
92 92
@@ -106,12 +106,12 @@ class UtilsDeTest extends UtilsTest
106 } 106 }
107 107
108 /** 108 /**
109 * Test autoLocale with an invalid value: defaults to en_US. 109 * Test autoLocale with an unavailable value: defaults to en_US.
110 */ 110 */
111 public function testAutoLocaleInvalid() 111 public function testAutoLocaleUnavailable()
112 { 112 {
113 $current = setlocale(LC_ALL, 0); 113 $current = setlocale(LC_ALL, 0);
114 autoLocale('pt_BR'); 114 autoLocale('mag_IN');
115 $this->assertEquals('en_US.utf8', setlocale(LC_ALL, 0)); 115 $this->assertEquals('en_US.utf8', setlocale(LC_ALL, 0));
116 116
117 setlocale(LC_ALL, $current); 117 setlocale(LC_ALL, $current);
diff --git a/tests/languages/en/UtilsEnTest.php b/tests/languages/en/UtilsEnTest.php
index d8680b2b..a74063ae 100644
--- a/tests/languages/en/UtilsEnTest.php
+++ b/tests/languages/en/UtilsEnTest.php
@@ -81,12 +81,12 @@ class UtilsEnTest extends UtilsTest
81 } 81 }
82 82
83 /** 83 /**
84 * Test autoLocale with multiples value, the second one is valid 84 * Test autoLocale with multiples value, the second one is available
85 */ 85 */
86 public function testAutoLocaleMultipleSecondValid() 86 public function testAutoLocaleMultipleSecondAvailable()
87 { 87 {
88 $current = setlocale(LC_ALL, 0); 88 $current = setlocale(LC_ALL, 0);
89 $header = 'pt_BR,fr-fr'; 89 $header = 'mag_IN,fr-fr';
90 autoLocale($header); 90 autoLocale($header);
91 $this->assertEquals('fr_FR.utf8', setlocale(LC_ALL, 0)); 91 $this->assertEquals('fr_FR.utf8', setlocale(LC_ALL, 0));
92 92
@@ -106,12 +106,12 @@ class UtilsEnTest extends UtilsTest
106 } 106 }
107 107
108 /** 108 /**
109 * Test autoLocale with an invalid value: defaults to en_US. 109 * Test autoLocale with an unavailable value: defaults to en_US.
110 */ 110 */
111 public function testAutoLocaleInvalid() 111 public function testAutoLocaleUnavailable()
112 { 112 {
113 $current = setlocale(LC_ALL, 0); 113 $current = setlocale(LC_ALL, 0);
114 autoLocale('pt_BR'); 114 autoLocale('mag_IN');
115 $this->assertEquals('en_US.utf8', setlocale(LC_ALL, 0)); 115 $this->assertEquals('en_US.utf8', setlocale(LC_ALL, 0));
116 116
117 setlocale(LC_ALL, $current); 117 setlocale(LC_ALL, $current);
diff --git a/tests/languages/fr/UtilsFrTest.php b/tests/languages/fr/UtilsFrTest.php
index 0d50a878..3dbb126f 100644
--- a/tests/languages/fr/UtilsFrTest.php
+++ b/tests/languages/fr/UtilsFrTest.php
@@ -81,12 +81,12 @@ class UtilsFrTest extends UtilsTest
81 } 81 }
82 82
83 /** 83 /**
84 * Test autoLocale with multiples value, the second one is valid 84 * Test autoLocale with multiples value, the second one is available
85 */ 85 */
86 public function testAutoLocaleMultipleSecondValid() 86 public function testAutoLocaleMultipleSecondAvailable()
87 { 87 {
88 $current = setlocale(LC_ALL, 0); 88 $current = setlocale(LC_ALL, 0);
89 $header = 'pt_BR,de-de'; 89 $header = 'mag_IN,de-de';
90 autoLocale($header); 90 autoLocale($header);
91 $this->assertEquals('de_DE.utf8', setlocale(LC_ALL, 0)); 91 $this->assertEquals('de_DE.utf8', setlocale(LC_ALL, 0));
92 92
@@ -106,12 +106,12 @@ class UtilsFrTest extends UtilsTest
106 } 106 }
107 107
108 /** 108 /**
109 * Test autoLocale with an invalid value: defaults to en_US. 109 * Test autoLocale with an unavailable value: defaults to en_US.
110 */ 110 */
111 public function testAutoLocaleInvalid() 111 public function testAutoLocaleUnavailable()
112 { 112 {
113 $current = setlocale(LC_ALL, 0); 113 $current = setlocale(LC_ALL, 0);
114 autoLocale('pt_BR'); 114 autoLocale('mag_IN');
115 $this->assertEquals('en_US.utf8', setlocale(LC_ALL, 0)); 115 $this->assertEquals('en_US.utf8', setlocale(LC_ALL, 0));
116 116
117 setlocale(LC_ALL, $current); 117 setlocale(LC_ALL, $current);