You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feature #16156 [Filesystem] Changed dumpFile to allow dumping to streams (markchalloner, pierredup)
This PR was merged into the 2.8 branch.
Discussion
----------
[Filesystem] Changed dumpFile to allow dumping to streams
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #10018
| License | MIT
| Doc PR | symfony/symfony-docs#5393
This is a follow-up of #14970 with comments addressed
Commits
-------
5ca7dee Fix mode
a17aa5e Fixed failing test for HHVM
61a3afd Removed unused logic in MockStream
247266c Update coding standard for MockStream
c6a7747 [Filesystem] added tempnam() stream wrapper aware version of PHP's native tempnam() and fixed dumpFile to allow dumping to streams
// Skip test if Phar disabled phar.readonly must be 0 in php.ini
1014
+
if (!\Phar::canWrite()) {
1015
+
$this->markTestSkipped('This test cannot run when phar.readonly is 1.');
1016
+
}
1017
+
1018
+
$scheme = 'phar://';
1019
+
$dirname = $scheme.$this->workspace;
1020
+
$pharname = 'foo.phar';
1021
+
1022
+
new \Phar($this->workspace.'/'.$pharname, 0, $pharname);
1023
+
// The phar:// stream does not support mode x: fails to create file, errors "failed to open stream: phar error: "$filename" is not a file in phar "$pharname"" and returns false
0 commit comments