File: preserve-include_path-in-test-suite.patch

package info (click to toggle)
php-console-commandline 1.2.4-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 688 kB
  • sloc: php: 1,396; xml: 156; sh: 5; makefile: 4
file content (31 lines) | stat: -rw-r--r-- 815 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
From: Guilhem Moulin <guilhem@debian.org>
Date: Wed, 12 Jan 2022 10:40:13 +0100
Subject: Preserve include_path in test suite.

We want to test with `-d include_path="$(CURDIR):/usr/share/php"` at
dh_auto_test stage, and with `-d include_path="/usr/share/php"` for
autopkgtests.

Origin: Debian
Forwarded: not-needed
---
 tests/tests.inc.php | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/tests/tests.inc.php b/tests/tests.inc.php
index 6c895c7..512eb4c 100644
--- a/tests/tests.inc.php
+++ b/tests/tests.inc.php
@@ -21,12 +21,6 @@
  * @since     File available since release 0.1.0
  */
 
-if (php_sapi_name() != 'cli') {
-    // tests with php-cgi need this
-    ini_set('include_path', ini_get('include_path') . PATH_SEPARATOR 
-        . dirname(__FILE__) . '/../');
-}
-
 /**
  * Required classes
  */