File tree 6 files changed +12
-24
lines changed
6 files changed +12
-24
lines changed Original file line number Diff line number Diff line change @@ -307,7 +307,7 @@ public function setPostFilterParameters(array $parameters)
307
307
*
308
308
* @param AbstractAggregation $aggregation
309
309
*
310
- * @return $this;
310
+ * @return $this
311
311
*/
312
312
public function addAggregation (AbstractAggregation $ aggregation )
313
313
{
Original file line number Diff line number Diff line change 20
20
class SpanFirstQueryTest extends \PHPUnit_Framework_TestCase
21
21
{
22
22
/**
23
- * @var Object.
23
+ * @var SpanQueryInterface|\PHPUnit_Framework_MockObject_MockObject
24
24
*/
25
25
protected $ mock ;
26
26
@@ -51,9 +51,7 @@ public function tearDown()
51
51
*/
52
52
public function testSpanFirstQueryToArray ()
53
53
{
54
- /** @var SpanQueryInterface $mock */
55
- $ mock = $ this ->mock ;
56
- $ query = new SpanFirstQuery ($ mock , 5 );
54
+ $ query = new SpanFirstQuery ($ this ->mock , 5 );
57
55
$ result = [
58
56
'match ' => [
59
57
'span_or ' => [ 'key ' => 'value ' ],
@@ -68,9 +66,7 @@ public function testSpanFirstQueryToArray()
68
66
*/
69
67
public function testSpanFirstQueryGetType ()
70
68
{
71
- /** @var SpanQueryInterface $mock */
72
- $ mock = $ this ->mock ;
73
- $ query = new SpanFirstQuery ($ mock , 5 );
69
+ $ query = new SpanFirstQuery ($ this ->mock , 5 );
74
70
$ result = $ query ->getType ();
75
71
$ this ->assertEquals ('span_first ' , $ result );
76
72
}
Original file line number Diff line number Diff line change 20
20
class SpanMultiTermQueryTest extends \PHPUnit_Framework_TestCase
21
21
{
22
22
/**
23
- * @var array.
23
+ * @var array
24
24
*/
25
25
protected $ mock ;
26
26
Original file line number Diff line number Diff line change 20
20
class SpanNearQueryTest extends \PHPUnit_Framework_TestCase
21
21
{
22
22
/**
23
- * @var Object.
23
+ * @var SpanQueryInterface|\PHPUnit_Framework_MockObject_MockObject
24
24
*/
25
25
protected $ mock ;
26
26
@@ -51,11 +51,9 @@ public function tearDown()
51
51
*/
52
52
public function testSpanMultiTermQueryToArray ()
53
53
{
54
- /** @var SpanQueryInterface $mock */
55
- $ mock = $ this ->mock ;
56
54
$ query = new SpanNearQuery (['name ' ]);
57
55
$ query ->setSlop (5 );
58
- $ query ->addQuery ($ mock );
56
+ $ query ->addQuery ($ this -> mock );
59
57
$ result = [
60
58
'clauses ' => [
61
59
0 => [
Original file line number Diff line number Diff line change 20
20
class SpanNotQueryTest extends \PHPUnit_Framework_TestCase
21
21
{
22
22
/**
23
- * @var Object.
23
+ * @var SpanQueryInterface|\PHPUnit_Framework_MockObject_MockObject
24
24
*/
25
25
protected $ mock ;
26
26
@@ -51,9 +51,7 @@ public function tearDown()
51
51
*/
52
52
public function testSpanNotQueryGetType ()
53
53
{
54
- /** @var SpanQueryInterface $mock */
55
- $ mock = $ this ->mock ;
56
- $ query = new SpanNotQuery ($ mock , $ mock );
54
+ $ query = new SpanNotQuery ($ this ->mock , $ this ->mock );
57
55
$ result = $ query ->getType ();
58
56
$ this ->assertEquals ('span_not ' , $ result );
59
57
}
@@ -63,9 +61,7 @@ public function testSpanNotQueryGetType()
63
61
*/
64
62
public function testSpanNotQueryToArray ()
65
63
{
66
- /** @var SpanQueryInterface $mock */
67
- $ mock = $ this ->mock ;
68
- $ query = new SpanNotQuery ($ mock , $ mock );
64
+ $ query = new SpanNotQuery ($ this ->mock , $ this ->mock );
69
65
$ result = [
70
66
'include ' => [
71
67
'span_or ' => ['key ' => 'value ' ],
Original file line number Diff line number Diff line change 20
20
class SpanOrQueryTest extends \PHPUnit_Framework_TestCase
21
21
{
22
22
/**
23
- * @var Object.
23
+ * @var SpanQueryInterface|\PHPUnit_Framework_MockObject_MockObject
24
24
*/
25
25
protected $ mock ;
26
26
@@ -61,10 +61,8 @@ public function testSpanOrQueryGetType()
61
61
*/
62
62
public function testSpanOrQueryToArray ()
63
63
{
64
- /** @var SpanQueryInterface $mock */
65
- $ mock = $ this ->mock ;
66
64
$ query = new SpanOrQuery ();
67
- $ query ->addQuery ($ mock );
65
+ $ query ->addQuery ($ this -> mock );
68
66
$ result = [
69
67
'clauses ' => [
70
68
0 => [
You can’t perform that action at this time.
0 commit comments