Skip to content

Commit 27fe3fc

Browse files
committed
Merge pull request #473
2 parents bac5b9b + 76cabea commit 27fe3fc

12 files changed

+51
-12
lines changed

tests/Model/BSONArrayTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
<?php
22

3-
namespace MongoDB\Tests;
3+
namespace MongoDB\Tests\Model;
44

55
use MongoDB\Model\BSONArray;
66
use MongoDB\Model\BSONDocument;
7+
use MongoDB\Tests\TestCase;
78

89
class BSONArrayTest extends TestCase
910
{

tests/Model/BSONDocumentTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
<?php
22

3-
namespace MongoDB\Tests;
3+
namespace MongoDB\Tests\Model;
44

55
use MongoDB\Model\BSONArray;
66
use MongoDB\Model\BSONDocument;
7+
use MongoDB\Tests\TestCase;
78
use ArrayObject;
89

910
class BSONDocumentTest extends TestCase

tests/Model/CollectionInfoTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace MongoDB\Tests;
3+
namespace MongoDB\Tests\Model;
44

55
use MongoDB\Model\CollectionInfo;
66
use MongoDB\Tests\TestCase;

tests/Model/DatabaseInfoTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace MongoDB\Tests;
3+
namespace MongoDB\Tests\Model;
44

55
use MongoDB\Model\DatabaseInfo;
66
use MongoDB\Tests\TestCase;

tests/Model/IndexInfoTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace MongoDB\Tests;
3+
namespace MongoDB\Tests\Model;
44

55
use MongoDB\Model\IndexInfo;
66
use MongoDB\Tests\TestCase;

tests/Model/IndexInputTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace MongoDB\Tests;
3+
namespace MongoDB\Tests\Model;
44

55
use MongoDB\Model\IndexInput;
66
use MongoDB\Tests\TestCase;

tests/Model/TypeMapArrayIteratorTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
<?php
22

3-
namespace MongoDB\Tests;
3+
namespace MongoDB\Tests\Model;
44

55
use MongoDB\Model\TypeMapArrayIterator;
6+
use MongoDB\Tests\TestCase;
67

78
class TypeMapArrayIteratorTest extends TestCase
89
{

tests/Operation/BulkWriteFunctionalTest.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,24 @@
11
<?php
22

3-
namespace MongoDB\Tests\Collection;
3+
namespace MongoDB\Tests\Operation;
44

55
use MongoDB\BulkWriteResult;
6+
use MongoDB\Collection;
67
use MongoDB\Driver\BulkWrite as Bulk;
78
use MongoDB\Driver\WriteConcern;
89
use MongoDB\Model\BSONDocument;
910
use MongoDB\Operation\BulkWrite;
1011

1112
class BulkWriteFunctionalTest extends FunctionalTestCase
1213
{
14+
private $collection;
1315
private $omitModifiedCount;
1416

1517
public function setUp()
1618
{
1719
parent::setUp();
1820

21+
$this->collection = new Collection($this->manager, $this->getDatabaseName(), $this->getCollectionName());
1922
$this->omitModifiedCount = version_compare($this->getServerVersion(), '2.6.0', '<');
2023
}
2124

tests/Operation/DeleteFunctionalTest.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,24 @@
11
<?php
22

3-
namespace MongoDB\Tests\Collection;
3+
namespace MongoDB\Tests\Operation;
44

55
use MongoDB\DeleteResult;
6+
use MongoDB\Collection;
67
use MongoDB\Driver\BulkWrite;
78
use MongoDB\Driver\WriteConcern;
89
use MongoDB\Operation\Delete;
910

1011
class DeleteFunctionalTest extends FunctionalTestCase
1112
{
13+
private $collection;
14+
15+
public function setUp()
16+
{
17+
parent::setUp();
18+
19+
$this->collection = new Collection($this->manager, $this->getDatabaseName(), $this->getCollectionName());
20+
}
21+
1222
public function testDeleteOne()
1323
{
1424
$this->createFixtures(3);

tests/Operation/InsertManyFunctionalTest.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,24 @@
11
<?php
22

3-
namespace MongoDB\Tests\Collection;
3+
namespace MongoDB\Tests\Operation;
44

5+
use MongoDB\Collection;
56
use MongoDB\InsertManyResult;
67
use MongoDB\Driver\WriteConcern;
78
use MongoDB\Model\BSONDocument;
89
use MongoDB\Operation\InsertMany;
910

1011
class InsertManyFunctionalTest extends FunctionalTestCase
1112
{
13+
private $collection;
14+
15+
public function setUp()
16+
{
17+
parent::setUp();
18+
19+
$this->collection = new Collection($this->manager, $this->getDatabaseName(), $this->getCollectionName());
20+
}
21+
1222
public function testInsertMany()
1323
{
1424
$documents = [

0 commit comments

Comments
 (0)