Skip to content

Commit 5f24d92

Browse files
committed
Functional test for aggregate command failure
1 parent 53c62cb commit 5f24d92

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?php
2+
3+
namespace MongoDB\Tests\Operation;
4+
5+
use MongoDB\Operation\Aggregate;
6+
7+
class AggregateFunctionalTest extends FunctionalTestCase
8+
{
9+
/**
10+
* @expectedException MongoDB\Driver\Exception\RuntimeException
11+
*/
12+
public function testUnrecognizedPipelineState()
13+
{
14+
$server = $this->getPrimaryServer();
15+
$operation = new Aggregate($this->getDatabaseName(), $this->getCollectionName(), [['$foo' => 1]]);
16+
$operation->execute($server);
17+
}
18+
}

0 commit comments

Comments
 (0)