Browse code

Merge pull request #820 from siburny/small-fixes-in-tests

Minor fixes to tests

Klaus Silveira authored on 14.11.2018 22:15:12 • GitHub committed on 14.11.2018 22:15:12
Showing 2 changed files

... ...
@@ -33,3 +33,5 @@ cache.properties
33 33
 composer.phar
34 34
 phpunit.xml
35 35
 .php_cs.cache
36
+web.config
37
+.vscode/
... ...
@@ -11,7 +11,9 @@ class InterfaceTest extends WebTestCase
11 11
 
12 12
     public static function setUpBeforeClass()
13 13
     {
14
-        if (getenv('TMP')) {
14
+        if (sys_get_temp_dir()) {
15
+            self::$tmpdir = sys_get_temp_dir();
16
+        } elseif (getenv('TMP')) {
15 17
             self::$tmpdir = getenv('TMP');
16 18
         } elseif (getenv('TMPDIR')) {
17 19
             self::$tmpdir = getenv('TMPDIR');
... ...
@@ -25,7 +27,7 @@ class InterfaceTest extends WebTestCase
25 27
         $fs->mkdir(self::$tmpdir);
26 28
 
27 29
         if (!is_writable(self::$tmpdir)) {
28
-            $this->markTestSkipped('There are no write permissions in order to create test repositories.');
30
+            self::markTestSkipped('There are no write permissions in order to create test repositories.');
29 31
         }
30 32
 
31 33
         $options['path'] = getenv('GIT_CLIENT') ?: '/usr/bin/git';