Skip to content

Commit f320c35

Browse files
committed
Use __DIR__-relative path in tests
Otherwise we can't run them from another directory, they'll fail instead.
1 parent 4f1103e commit f320c35

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

ext/exif/tests/bug78793.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Bug #78793: Use-after-free in exif parsing under memory sanitizer
44
exif
55
--FILE--
66
<?php
7-
$f = "ext/exif/tests/bug77950.tiff";
7+
$f = __DIR__ . "/bug77950.tiff";
88
for ($i = 0; $i < 10; $i++) {
99
@exif_read_data($f);
1010
}

ext/soap/tests/bug75306.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ soap
77
$options = array("cache_wsdl" => WSDL_CACHE_NONE);
88
// Need a warm-up for globals
99
for ($i = 0; $i < 10; $i++) {
10-
$client = new SoapClient("ext/soap/tests/test.wsdl", $options);
10+
$client = new SoapClient(__DIR__ . "/test.wsdl", $options);
1111
}
1212
$usage = memory_get_usage();
1313
for ($i = 0; $i < 10; $i++) {
14-
$client = new SoapClient("ext/soap/tests/test.wsdl", $options);
14+
$client = new SoapClient(__DIR__ . "/test.wsdl", $options);
1515
}
1616
$usage_delta = memory_get_usage() - $usage;
1717
var_dump($usage_delta);

0 commit comments

Comments
 (0)