fix(tests): 修正测试文件中的路径引用

- 修正 empty-test.phpt 中的静态属性测试文件路径
- 修正 isset-test.phpt 中的静态属性测试文件路径
- 修正 magic-constants.phpt 中 __DIR__ 魔术常量的期望输出
- 修正 ref-call-arg.phpt 中 zip 文件的路径引用
- 修正 static_class_property_read_write.phpt 中的测试文件路径
- 修正 universal_method_expr.phpt 中 Assert.php 的引入路径
pull/1/head
韩天峰 3 months ago
parent 0043fc78f8
commit 000b6a221d
  1. 2
      tests/aot/basic/magic-constants.phpt
  2. 0
      tests/aot/basic/test_include.inc
  3. 2
      tests/aot/empty/empty-test.phpt
  4. 2
      tests/aot/empty/isset-test.phpt
  5. 2
      tests/aot/ref/ref-call-arg.phpt
  6. 2
      tests/aot/static/static_class_property_read_write.phpt
  7. 2
      tests/aot/universal_method/universal_method_expr.phpt

@ -30,7 +30,7 @@ function main() {
--EXPECTF--
__LINE__: int(%d)
__FILE__: string(%d) "magic-constants.php"
__DIR__: string(%d) "aot"
__DIR__: string(%d) "basic"
__FUNCTION__ in function: string(%d) "testFunction"
__METHOD__: string(%d) "TestMagicConst::testMethod"
__CLASS__: string(%d) "TestMagicConst"

@ -2,7 +2,7 @@
empty (linked expr)
--FILE--
<?php
include __DIR__ . '/static_property_test.inc';
include __DIR__ . '/../static_property_test.inc';
$arr = array(
array(2, 2)
);

@ -2,7 +2,7 @@
isset (linked expr)
--FILE--
<?php
include __DIR__ . '/static_property_test.inc';
include __DIR__ . '/../static_property_test.inc';
$arr = array(
array(2, 2)
);

@ -5,7 +5,7 @@ ref call arg
function main()
{
$zip = new ZipArchive();
$path = realpath(__DIR__ . '/../../../data/test.zip');
$path = realpath(__DIR__ . '/../../../../data/test.zip');
if ($zip->open($path) === TRUE) {
for ($idx = 0; $s = $zip->statIndex($idx); $idx++) {
$rs = $zip->getExternalAttributesIndex($idx, $opsys, $attr);

@ -3,7 +3,7 @@ Static Class Property Read/Write Test
--FILE--
<?php
include __DIR__ . '/static_property_test.inc';
include __DIR__ . '/../static_property_test.inc';
// Test reading static properties
echo "Initial public property: " . TestClass::$public_static_property . "\n";

@ -51,7 +51,7 @@ class Helper {
function main()
{
require __DIR__ . '/../../src/Assert.php';
require __DIR__ . '/../../../src/Assert.php';
// --- Test 1: FuncCall -> universal method ---
Assert::eq(getString()->length(), 11);

Loading…
Cancel
Save