diff --git a/Samples/PizzaTest.php b/examples/PizzaTest.php similarity index 77% rename from Samples/PizzaTest.php rename to examples/PizzaTest.php index 5ccfdbc..21cb964 100644 --- a/Samples/PizzaTest.php +++ b/examples/PizzaTest.php @@ -1,6 +1,6 @@ connection)) { - $this->connection = new \PHPUnit\Extensions\Mongo\Client\Connector(new \MongoClient()); + $this->connection = new \Zumba\PHPUnit\Extensions\Mongo\Client\Connector(new \MongoClient()); $this->connection->setDb(static::DEFAULT_DATABASE); } return $this->connection; @@ -28,7 +28,7 @@ public function getConnection() { public function getDataSet() { if (empty($this->dataSet)) { - $this->dataSet = new PHPUnit\Extensions\Mongo\DataSet\DataSet($this->getConnection()); + $this->dataSet = new \Zumba\PHPUnit\Extensions\Mongo\DataSet\DataSet($this->getConnection()); $this->dataSet->setFixture($this->fixture); } return $this->dataSet; diff --git a/phpunit.xml b/phpunit.xml index 4bbd808..2766496 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,7 +1,7 @@ - ./Tests + ./tests - ./Samples + ./examples - ./PHPUnit/Extensions\Mongo\AutoLoader.php - ./Tests + ./src/Zumba/PHPUnit/Extensions/Mongo/AutoLoader.php + ./tests - ./PHPUnit + ./src/Zumba/PHPUnit - ./PHPUnit/Extensions\Mongo\AutoLoader.php + ./src/Zumba/PHPUnit/Extensions/Mongo/AutoLoader.php diff --git a/PHPUnit/Extensions/Mongo/AutoLoader.php b/src/Zumba/PHPUnit/Extensions/Mongo/AutoLoader.php similarity index 76% rename from PHPUnit/Extensions/Mongo/AutoLoader.php rename to src/Zumba/PHPUnit/Extensions/Mongo/AutoLoader.php index 43c6955..3fc1136 100644 --- a/PHPUnit/Extensions/Mongo/AutoLoader.php +++ b/src/Zumba/PHPUnit/Extensions/Mongo/AutoLoader.php @@ -1,10 +1,10 @@ array(dirname(dirname(dirname(__DIR__))) . '/') + 'Zumba' => array(dirname(dirname(dirname(dirname(__DIR__)))) . '/') ); $classname = ltrim($classname, '\\'); foreach ($namespaces as $ns => $paths) { diff --git a/PHPUnit/Extensions/Mongo/Base/Connector.php b/src/Zumba/PHPUnit/Extensions/Mongo/Base/Connector.php similarity index 90% rename from PHPUnit/Extensions/Mongo/Base/Connector.php rename to src/Zumba/PHPUnit/Extensions/Mongo/Base/Connector.php index a94ffd8..53ed988 100644 --- a/PHPUnit/Extensions/Mongo/Base/Connector.php +++ b/src/Zumba/PHPUnit/Extensions/Mongo/Base/Connector.php @@ -1,6 +1,6 @@ connection = $connection; @@ -36,7 +36,7 @@ public function __construct(Connector $connection) { * see $this->fixture * * @param array $data - * @return PHPUnit\Extensions\Mongo\DataSet\DataSet + * @return Zumba\PHPUnit\Extensions\Mongo\DataSet\DataSet */ public function setFixture(array $data) { $this->fixture = $data; @@ -46,7 +46,7 @@ public function setFixture(array $data) { /** * Drops all collections specified in the fixture keys. * - * @return PHPUnit\Extensions\Mongo\DataSet\DataSet + * @return Zumba\PHPUnit\Extensions\Mongo\DataSet\DataSet */ public function dropAllCollections() { foreach (array_keys($this->fixture) as $collection) { @@ -58,7 +58,7 @@ public function dropAllCollections() { /** * Creates all collections with data from the fixture. * - * @return PHPUnit\Extensions\Mongo\DataSet\DataSet + * @return Zumba\PHPUnit\Extensions\Mongo\DataSet\DataSet */ public function buildCollections() { foreach ($this->fixture as $collection => $data) { diff --git a/PHPUnit/Extensions/Mongo/TestCase.php b/src/Zumba/PHPUnit/Extensions/Mongo/TestCase.php similarity index 77% rename from PHPUnit/Extensions/Mongo/TestCase.php rename to src/Zumba/PHPUnit/Extensions/Mongo/TestCase.php index 8c455c0..b20db93 100644 --- a/PHPUnit/Extensions/Mongo/TestCase.php +++ b/src/Zumba/PHPUnit/Extensions/Mongo/TestCase.php @@ -1,7 +1,7 @@ setDb('test'); - $this->assertInstanceOf('PHPUnit\Extensions\Mongo\Client\Connector', $connection); + $this->assertInstanceOf('Zumba\PHPUnit\Extensions\Mongo\Client\Connector', $connection); $connection->collection('test')->insert(array( 'document' => 'test document' ));