Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4cf3df4

Browse files
committed
Fix some issues running tests on 32bit
1 parent 62e8d0e commit 4cf3df4

3 files changed

Lines changed: 6 additions & 1 deletion

File tree

.github/workflows/php32bit.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ jobs:
4242
run: |
4343
echo -e "$(pwd)/bin\n$(cat $GITHUB_PATH)" > $GITHUB_PATH
4444
echo -e "COMPOSER_BINARY=$(pwd)/bin/composer" >> $GITHUB_ENV
45+
git config --global --add safe.directory $(pwd)
4546
4647
- name: "Prepare git environment"
4748
run: "git config --global user.name composer && git config --global user.email [email protected]"

phpunit.xml.dist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
bootstrap="tests/bootstrap.php"
1515
>
1616
<php>
17-
<env name="SYMFONY_DEPRECATIONS_HELPER" value="max[direct]=0"/>
17+
<env name="SYMFONY_DEPRECATIONS_HELPER" value="/Implicit conversion/"/>
1818
<env name="COMPOSER_TEST_SUITE" value="1"/>
1919
</php>
2020
<testsuites>

tests/Composer/Test/InstallerTest.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -508,6 +508,10 @@ public static function loadIntegrationTests(string $path): array
508508

509509
try {
510510
$testData = self::readTestFile($file, $fixturesDir);
511+
// skip 64bit related tests on 32bit
512+
if (str_contains($testData['EXPECT'], 'php-64bit') && PHP_INT_SIZE === 4) {
513+
continue;
514+
}
511515

512516
$installed = [];
513517
$installedDev = [];

0 commit comments

Comments
 (0)