����JFIF��x�x����'
Server IP : 78.140.185.180 / Your IP : 3.141.42.23 Web Server : LiteSpeed System : Linux cpanel13.v.fozzy.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64 User : builderbox ( 1072) PHP Version : 7.3.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/builderbox/public_html/vendor/maennchen/zipstream-php/test/bug/ |
Upload File : |
<?php declare(strict_types=1); namespace BugHonorFileTimeTest; use DateTime; use PHPUnit\Framework\TestCase; use ZipStream\Option\{ Archive, File }; use ZipStream\ZipStream; use function fopen; /** * Asserts that specified last-modified timestamps are not overwritten when a * file is added */ class BugHonorFileTimeTest extends TestCase { public function testHonorsFileTime(): void { $archiveOpt = new Archive(); $fileOpt = new File(); $expectedTime = new DateTime('2019-04-21T19:25:00-0800'); $archiveOpt->setOutputStream(fopen('php://memory', 'wb')); $fileOpt->setTime(clone $expectedTime); $zip = new ZipStream(null, $archiveOpt); $zip->addFile('sample.txt', 'Sample', $fileOpt); $zip->finish(); $this->assertEquals($expectedTime, $fileOpt->getTime()); } }