public function test_it_should_update_all_packages() { $zipperMock = $this->getMock('MyBuilder\\Conductor\\PackageZipper', array(), array(array())); $zipperMock->expects($this->any())->method('zip')->will($this->returnCallback(function ($a) { return $a; })); $files = $this->conductor->updatePackages(array(__DIR__ . '/fixtures/packages/*'), $zipperMock); $this->assertEquals(array(__DIR__ . '/fixtures/packages/package-a/composer.json', __DIR__ . '/fixtures/packages/package-a-changed/composer.json'), array_map(null, $files)); }