Skip to content

Commit

Permalink
skip pclzip notice
Browse files Browse the repository at this point in the history
  • Loading branch information
liborm85 committed Oct 18, 2020
1 parent 170bde4 commit 764db15
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions tests/Common/Tests/Adapter/Zip/AbstractZipAdapterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
namespace Common\Tests\Adapter\Zip;

use PhpOffice\Common\Tests\TestHelperZip;
use PHPUnit\Framework\Error\Notice;
use PHPUnit\Framework\Error\Warning;

abstract class AbstractZipAdapterTest extends \PHPUnit\Framework\TestCase
{
Expand Down Expand Up @@ -47,6 +49,13 @@ public function testClose()

public function testAddFromString()
{
// pclzip/pclzip library is not compatible with PHP 7.1+, issue: https://github.com/ivanlanin/pclzip/pull/8
if (\PHP_VERSION_ID >= 80000) {
$this->expectException(get_class(new Warning()));
} else if (\PHP_VERSION_ID >= 71000) {
$this->expectException(get_class(new Notice()));
}

$expectedPath = 'file.test';
$expectedContent = 'Content';

Expand Down

0 comments on commit 764db15

Please sign in to comment.