Permalink
Browse files

restore PHP 5.3 compatibility

  • Loading branch information...
remicollet authored and theseer committed Feb 11, 2019
1 parent 950c355 commit f09ef9d54d9260242ba371d1e6d3c2188e16ee1d
Showing with 5 additions and 5 deletions.
  1. +2 −2 src/ComposerIterator.php
  2. +3 −3 tests/ComposerIteratorTest.php
@@ -6,9 +6,9 @@ class ComposerIterator implements \Iterator {
/**
* @var array
*/
private $directories = [];
private $directories = array();
private $seen = [];
private $seen = array();
private $pos = 0;
@@ -1,4 +1,4 @@
<?php declare(strict_types=1);
<?php
namespace TheSeer\Autoload;
use PHPUnit\Framework\TestCase;
@@ -7,10 +7,10 @@ class ComposerIteratorTest extends TestCase {
public function testRecursionIsHandledProperly() {
$iterator = new ComposerIterator(new \SplFileInfo(__DIR__ . '/_data/recursion/composer.json'));
$expected = [
$expected = array(
__DIR__ . '/_data/recursion/vendor/foo/bar',
__DIR__ . '/_data/recursion/vendor/bar/foo'
];
);
foreach($iterator as $pos => $entry) {
$this->assertEquals($expected[$pos], $entry);
}

0 comments on commit f09ef9d

Please sign in to comment.