-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathphpunit-coverage.xml
More file actions
91 lines (84 loc) · 4.94 KB
/
Copy pathphpunit-coverage.xml
File metadata and controls
91 lines (84 loc) · 4.94 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" backupGlobals="false" backupStaticProperties="false" beStrictAboutOutputDuringTests="false" beStrictAboutTestsThatDoNotTestAnything="true" bootstrap="vendor/autoload.php" cacheDirectory=".cache/phpunit" cacheResult="true" colors="true" failOnRisky="true" failOnWarning="true" processIsolation="false" stopOnError="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/12.5/phpunit.xsd">
<testsuites>
<testsuite name="Feature">
<directory suffix="Test.php">./packages/*/tests/Feature</directory>
<directory suffix="Test.php">./tests/Integration/Feature</directory>
<exclude>./packages/*/tests/Browser</exclude>
</testsuite>
<testsuite name="Integration">
<directory suffix="Test.php">./packages/*/tests/Integration</directory>
<directory suffix="Test.php">./tests/Integration</directory>
<exclude>./tests/Integration/Feature</exclude>
<exclude>./packages/*/tests/Browser</exclude>
</testsuite>
<testsuite name="Unit">
<directory suffix="Test.php">./packages/*/tests/Unit</directory>
<directory suffix="Test.php">./tests/Unit</directory>
<exclude>./packages/*/tests/Browser</exclude>
</testsuite>
</testsuites>
<source restrictNotices="true" restrictWarnings="true" ignoreSuppressionOfDeprecations="true" ignoreIndirectDeprecations="true">
<include>
<directory suffix=".php">packages/admin/src/.</directory>
<directory suffix=".php">packages/core/src/.</directory>
<directory suffix=".php">packages/frontend/src/.</directory>
<directory suffix=".php">packages/installer/src/.</directory>
<directory suffix=".php">packages/marketplace/src/.</directory>
</include>
</source>
<php>
<!--
Coverage variant of phpunit.xml. Identical to it except for this limit;
CoverageWorkflowTest fails if the two files drift in any other way, so edit
them together.
Coverage needs more than a normal test worker does. In parallel mode each
worker writes its coverage set to a temp file (~200MB each) and the parent
deserialises and merges all of them, so the parent peaks in the multi GB
range while the workers stay around 300MB. The limit applies to parent and
workers alike, because PHPUnit's <ini> handling cannot distinguish them, so
it is sized for the parent's merge step without reserving most of a
hosted runner for one PHP process.
Note for editors: XML forbids a double hyphen inside a comment, and this
file is parsed by paratest before any test runs. Name PHPUnit flags in
prose here, never with their leading hyphens, or the whole run dies in
Builder.php with "Double hyphen within comment".
The parent's historical peak was driven by the coverage-php report, which
Pest appends to its own coverage flag because that serialized dump is how
it computes the min gate. php-code-coverage's Serializer therefore builds one
`serialize()` string of the whole merged object in a single allocation,
while still holding that object. Both live at once, so the limit has to
cover roughly twice the merged set.
CI and the standard local Composer commands avoid that duplicate
serialization by requesting reports directly from PHPUnit. CI additionally
shards the tests, then merges the compact Clover reports and enforces the
line threshold separately.
This value is not a guess, and each raise is recorded against a run that
measured it:
4G -> 8G run 30619680673 died on `tried to allocate 1608519680 bytes`
8G -> 12G run 30988466900 died on `tried to allocate 1820811480 bytes`,
reproduced locally at 4 processes with a 1163923456 byte
allocation; 12G is the first value that completed the run.
Those historical limits applied to the removed serialized report path.
Four gigabytes is the bounded limit for the direct-report path. Raise it
only against a measured allocation from a run that names the shortfall,
not against headroom.
-->
<ini name="memory_limit" value="4G"/>
<server name="APP_ENV" value="testing"/>
<env name="APP_KEY" value="12345678901234567890123456789012"/>
<env name="BCRYPT_ROUNDS" value="4"/>
<env name="CACHE_STORE" value="array" force="true"/>
<env name="CURATOR_GLIDE_TOKEN" value="123456789"/>
<env name="DB_CONNECTION" value="sqlite"/>
<env name="DB_DATABASE" value=":memory:"/>
<env name="DB_URL" value=""/>
<env name="MAIL_MAILER" value="array"/>
<env name="PULSE_ENABLED" value="false"/>
<env name="QUEUE_CONNECTION" value="sync" force="true"/>
<env name="SESSION_DRIVER" value="array" force="true"/>
<env name="TELESCOPE_ENABLED" value="false"/>
<env name="CAPELL_HTML_CACHE" value="false"/>
<env name="SETTINGS_CACHE_ENABLED" value="true"/>
</php>
</phpunit>