Passed
Pull Request — master (#64)
by
unknown
03:05
created
Lib/ElasticSearchPhpClient/tests/Elasticsearch/Tests/Endpoints/MgetTest.php 3 patches
Indentation   +40 added lines, -40 removed lines patch added patch discarded remove patch
@@ -30,14 +30,14 @@  discard block
 block discarded – undo
30 30
         $body['docs'] = '1';
31 31
 
32 32
         $mockTransport = m::mock('\Elasticsearch\Transport')
33
-                         ->shouldReceive('performRequest')->once()
34
-                         ->with(
35
-                                 m::any(),
36
-                                 m::any(),
37
-                                 array(),
38
-                                 $body
39
-                             )
40
-                         ->getMock();
33
+                            ->shouldReceive('performRequest')->once()
34
+                            ->with(
35
+                                    m::any(),
36
+                                    m::any(),
37
+                                    array(),
38
+                                    $body
39
+                                )
40
+                            ->getMock();
41 41
 
42 42
         $action = new Mget($mockTransport);
43 43
         $action->setBody($body)
@@ -52,14 +52,14 @@  discard block
 block discarded – undo
52 52
         $uri = '/_mget';
53 53
         $body['docs'] = '1';
54 54
         $mockTransport = m::mock('\Elasticsearch\Transport')
55
-                         ->shouldReceive('performRequest')->once()
56
-                         ->with(
57
-                                 m::any(),
58
-                                 $uri,
59
-                                 array(),
60
-                                 $body
61
-                             )
62
-                         ->getMock();
55
+                            ->shouldReceive('performRequest')->once()
56
+                            ->with(
57
+                                    m::any(),
58
+                                    $uri,
59
+                                    array(),
60
+                                    $body
61
+                                )
62
+                            ->getMock();
63 63
 
64 64
         $action = new Mget($mockTransport);
65 65
         $action->setBody($body)->performRequest();
@@ -71,14 +71,14 @@  discard block
 block discarded – undo
71 71
         $uri = '/testIndex/_mget';
72 72
         $body['docs'] = '1';
73 73
         $mockTransport = m::mock('\Elasticsearch\Transport')
74
-                         ->shouldReceive('performRequest')->once()
75
-                         ->with(
76
-                                 m::any(),
77
-                                 $uri,
78
-                                 array(),
79
-                                 $body
80
-                             )
81
-                         ->getMock();
74
+                            ->shouldReceive('performRequest')->once()
75
+                            ->with(
76
+                                    m::any(),
77
+                                    $uri,
78
+                                    array(),
79
+                                    $body
80
+                                )
81
+                            ->getMock();
82 82
 
83 83
         $action = new Mget($mockTransport);
84 84
         $action->setBody($body)->setIndex('testIndex')
@@ -92,14 +92,14 @@  discard block
 block discarded – undo
92 92
         $uri = '/_all/testType/_mget';
93 93
         $body['docs'] = '1';
94 94
         $mockTransport = m::mock('\Elasticsearch\Transport')
95
-                         ->shouldReceive('performRequest')->once()
96
-                         ->with(
97
-                                 m::any(),
98
-                                 $uri,
99
-                                 array(),
100
-                                 $body
101
-                             )
102
-                         ->getMock();
95
+                            ->shouldReceive('performRequest')->once()
96
+                            ->with(
97
+                                    m::any(),
98
+                                    $uri,
99
+                                    array(),
100
+                                    $body
101
+                                )
102
+                            ->getMock();
103 103
 
104 104
         $action = new Mget($mockTransport);
105 105
         $action->setBody($body)->setType('testType')
@@ -113,14 +113,14 @@  discard block
 block discarded – undo
113 113
         $uri = '/testIndex/testType/_mget';
114 114
         $body['docs'] = '1';
115 115
         $mockTransport = m::mock('\Elasticsearch\Transport')
116
-                         ->shouldReceive('performRequest')->once()
117
-                         ->with(
118
-                                 m::any(),
119
-                                 $uri,
120
-                                 array(),
121
-                                 m::any()
122
-                             )
123
-                         ->getMock();
116
+                            ->shouldReceive('performRequest')->once()
117
+                            ->with(
118
+                                    m::any(),
119
+                                    $uri,
120
+                                    array(),
121
+                                    m::any()
122
+                                )
123
+                            ->getMock();
124 124
 
125 125
         $action = new Mget($mockTransport);
126 126
         $action->setBody($body)->setIndex('testIndex')
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
                          ->with(
35 35
                                  m::any(),
36 36
                                  m::any(),
37
-                                 array(),
37
+                                 array (),
38 38
                                  $body
39 39
                              )
40 40
                          ->getMock();
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
                          ->with(
57 57
                                  m::any(),
58 58
                                  $uri,
59
-                                 array(),
59
+                                 array (),
60 60
                                  $body
61 61
                              )
62 62
                          ->getMock();
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
                          ->with(
76 76
                                  m::any(),
77 77
                                  $uri,
78
-                                 array(),
78
+                                 array (),
79 79
                                  $body
80 80
                              )
81 81
                          ->getMock();
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
                          ->with(
97 97
                                  m::any(),
98 98
                                  $uri,
99
-                                 array(),
99
+                                 array (),
100 100
                                  $body
101 101
                              )
102 102
                          ->getMock();
@@ -117,7 +117,7 @@  discard block
 block discarded – undo
117 117
                          ->with(
118 118
                                  m::any(),
119 119
                                  $uri,
120
-                                 array(),
120
+                                 array (),
121 121
                                  m::any()
122 122
                              )
123 123
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +6 added lines, -12 removed lines patch added patch discarded remove patch
@@ -18,15 +18,13 @@  discard block
 block discarded – undo
18 18
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
19 19
  * @link    http://elasticsearch.org
20 20
  */
21
-class MgetTest extends \PHPUnit_Framework_TestCase
22
-{
21
+class MgetTest extends \PHPUnit_Framework_TestCase {
23 22
 
24 23
     public function tearDown() {
25 24
         m::close();
26 25
     }
27 26
 
28
-    public function testSetBody()
29
-    {
27
+    public function testSetBody() {
30 28
         $body['docs'] = '1';
31 29
 
32 30
         $mockTransport = m::mock('\Elasticsearch\Transport')
@@ -46,8 +44,7 @@  discard block
 block discarded – undo
46 44
     }
47 45
 
48 46
 
49
-    public function testGetURIWithNoIndexOrType()
50
-    {
47
+    public function testGetURIWithNoIndexOrType() {
51 48
 
52 49
         $uri = '/_mget';
53 50
         $body['docs'] = '1';
@@ -66,8 +63,7 @@  discard block
 block discarded – undo
66 63
 
67 64
     }
68 65
 
69
-    public function testGetURIWithIndexButNoType()
70
-    {
66
+    public function testGetURIWithIndexButNoType() {
71 67
         $uri = '/testIndex/_mget';
72 68
         $body['docs'] = '1';
73 69
         $mockTransport = m::mock('\Elasticsearch\Transport')
@@ -86,8 +82,7 @@  discard block
 block discarded – undo
86 82
 
87 83
     }
88 84
 
89
-    public function testGetURIWithTypeButNoIndex()
90
-    {
85
+    public function testGetURIWithTypeButNoIndex() {
91 86
 
92 87
         $uri = '/_all/testType/_mget';
93 88
         $body['docs'] = '1';
@@ -107,8 +102,7 @@  discard block
 block discarded – undo
107 102
 
108 103
     }
109 104
 
110
-    public function testGetURIWithBothTypeAndIndex()
111
-    {
105
+    public function testGetURIWithBothTypeAndIndex() {
112 106
 
113 107
         $uri = '/testIndex/testType/_mget';
114 108
         $body['docs'] = '1';
Please login to merge, or discard this patch.
ElasticSearchPhpClient/tests/Elasticsearch/Tests/Endpoints/MsearchTest.php 3 patches
Indentation   +58 added lines, -58 removed lines patch added patch discarded remove patch
@@ -46,14 +46,14 @@  discard block
 block discarded – undo
46 46
         $uri = '/_msearch';
47 47
         $body = 'abc';
48 48
         $mockTransport = m::mock('\Elasticsearch\Transport')
49
-                         ->shouldReceive('performRequest')->once()
50
-                         ->with(
51
-                                 m::any(),
52
-                                 $uri,
53
-                                 array(),
54
-                                 $body
55
-                             )
56
-                         ->getMock();
49
+                            ->shouldReceive('performRequest')->once()
50
+                            ->with(
51
+                                    m::any(),
52
+                                    $uri,
53
+                                    array(),
54
+                                    $body
55
+                                )
56
+                            ->getMock();
57 57
         $mockSerializer = m::mock('\Elasticsearch\Serializers\ArrayToJSONSerializer');
58 58
         
59 59
         $action = new Msearch($mockTransport, $mockSerializer);
@@ -66,14 +66,14 @@  discard block
 block discarded – undo
66 66
         $uri = '/testIndex/_msearch';
67 67
         $body = 'abc';
68 68
         $mockTransport = m::mock('\Elasticsearch\Transport')
69
-                         ->shouldReceive('performRequest')->once()
70
-                         ->with(
71
-                                 m::any(),
72
-                                 $uri,
73
-                                 array(),
74
-                                 $body
75
-                             )
76
-                         ->getMock();
69
+                            ->shouldReceive('performRequest')->once()
70
+                            ->with(
71
+                                    m::any(),
72
+                                    $uri,
73
+                                    array(),
74
+                                    $body
75
+                                )
76
+                            ->getMock();
77 77
 
78 78
         $mockSerializer = m::mock('\Elasticsearch\Serializers\ArrayToJSONSerializer');
79 79
         
@@ -89,14 +89,14 @@  discard block
 block discarded – undo
89 89
         $uri = '/_all/testType/_msearch';
90 90
         $body = 'abc';
91 91
         $mockTransport = m::mock('\Elasticsearch\Transport')
92
-                         ->shouldReceive('performRequest')->once()
93
-                         ->with(
94
-                                 m::any(),
95
-                                 $uri,
96
-                                 array(),
97
-                                 $body
98
-                             )
99
-                         ->getMock();
92
+                            ->shouldReceive('performRequest')->once()
93
+                            ->with(
94
+                                    m::any(),
95
+                                    $uri,
96
+                                    array(),
97
+                                    $body
98
+                                )
99
+                            ->getMock();
100 100
 
101 101
         $mockSerializer = m::mock('\Elasticsearch\Serializers\ArrayToJSONSerializer');
102 102
         
@@ -112,14 +112,14 @@  discard block
 block discarded – undo
112 112
         $uri = '/testIndex/testType/_msearch';
113 113
         $body = 'abc';
114 114
         $mockTransport = m::mock('\Elasticsearch\Transport')
115
-                         ->shouldReceive('performRequest')->once()
116
-                         ->with(
117
-                                 m::any(),
118
-                                 $uri,
119
-                                 array(),
120
-                                 $body
121
-                             )
122
-                         ->getMock();
115
+                            ->shouldReceive('performRequest')->once()
116
+                            ->with(
117
+                                    m::any(),
118
+                                    $uri,
119
+                                    array(),
120
+                                    $body
121
+                                )
122
+                            ->getMock();
123 123
 
124 124
         $mockSerializer = m::mock('\Elasticsearch\Serializers\ArrayToJSONSerializer');
125 125
         
@@ -135,14 +135,14 @@  discard block
 block discarded – undo
135 135
     {
136 136
         $body = 'abc';
137 137
         $mockTransport = m::mock('\Elasticsearch\Transport')
138
-                         ->shouldReceive('performRequest')->once()
139
-                         ->with(
140
-                                 'GET',
141
-                                 '/testIndex/testType/_msearch',
142
-                                 array(),
143
-                                 $body
144
-                             )
145
-                         ->getMock();
138
+                            ->shouldReceive('performRequest')->once()
139
+                            ->with(
140
+                                    'GET',
141
+                                    '/testIndex/testType/_msearch',
142
+                                    array(),
143
+                                    $body
144
+                                )
145
+                            ->getMock();
146 146
 
147 147
         $mockSerializer = m::mock('\Elasticsearch\Serializers\ArrayToJSONSerializer');
148 148
         
@@ -159,26 +159,26 @@  discard block
 block discarded – undo
159 159
         $body = array(array('query'=>array('match_all' => array())),array('query'=>array('match_all' => array())));
160 160
         $serializedBody = json_encode($body[0])."\n".json_encode($body[1])."\n";
161 161
         $mockTransport = m::mock('\Elasticsearch\Transport')
162
-                         ->shouldReceive('performRequest')->once()
163
-                         ->with(
164
-                                 m::any(),
165
-                                 $uri,
166
-                                 array(),
167
-                                 $serializedBody
168
-                             )
169
-                         ->getMock();
162
+                            ->shouldReceive('performRequest')->once()
163
+                            ->with(
164
+                                    m::any(),
165
+                                    $uri,
166
+                                    array(),
167
+                                    $serializedBody
168
+                                )
169
+                            ->getMock();
170 170
 
171 171
         $mockSerializer = m::mock('\Elasticsearch\Serializers\ArrayToJSONSerializer')
172
-                          ->shouldReceive('serialize')
173
-                          ->once()
174
-                          ->with($body[0])
175
-                          ->andReturn(json_encode($body[0]))
176
-                          ->getMock()
177
-                          ->shouldReceive('serialize')
178
-                          ->once()
179
-                          ->with($body[1])
180
-                          ->andReturn(json_encode($body[1]))
181
-                          ->getMock();
172
+                            ->shouldReceive('serialize')
173
+                            ->once()
174
+                            ->with($body[0])
175
+                            ->andReturn(json_encode($body[0]))
176
+                            ->getMock()
177
+                            ->shouldReceive('serialize')
178
+                            ->once()
179
+                            ->with($body[1])
180
+                            ->andReturn(json_encode($body[1]))
181
+                            ->getMock();
182 182
 
183 183
         $action = new Msearch($mockTransport, $mockSerializer);
184 184
         $action->setBody($body)->performRequest();
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
                          ->with(
51 51
                                  m::any(),
52 52
                                  $uri,
53
-                                 array(),
53
+                                 array (),
54 54
                                  $body
55 55
                              )
56 56
                          ->getMock();
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
                          ->with(
71 71
                                  m::any(),
72 72
                                  $uri,
73
-                                 array(),
73
+                                 array (),
74 74
                                  $body
75 75
                              )
76 76
                          ->getMock();
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
                          ->with(
94 94
                                  m::any(),
95 95
                                  $uri,
96
-                                 array(),
96
+                                 array (),
97 97
                                  $body
98 98
                              )
99 99
                          ->getMock();
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
                          ->with(
117 117
                                  m::any(),
118 118
                                  $uri,
119
-                                 array(),
119
+                                 array (),
120 120
                                  $body
121 121
                              )
122 122
                          ->getMock();
@@ -139,7 +139,7 @@  discard block
 block discarded – undo
139 139
                          ->with(
140 140
                                  'GET',
141 141
                                  '/testIndex/testType/_msearch',
142
-                                 array(),
142
+                                 array (),
143 143
                                  $body
144 144
                              )
145 145
                          ->getMock();
@@ -156,14 +156,14 @@  discard block
 block discarded – undo
156 156
     public function testSerializeArrayBody()
157 157
     {
158 158
         $uri = '/_msearch';
159
-        $body = array(array('query'=>array('match_all' => array())),array('query'=>array('match_all' => array())));
160
-        $serializedBody = json_encode($body[0])."\n".json_encode($body[1])."\n";
159
+        $body = array (array ('query'=>array ('match_all' => array ())), array ('query'=>array ('match_all' => array ())));
160
+        $serializedBody = json_encode($body[0]) . "\n" . json_encode($body[1]) . "\n";
161 161
         $mockTransport = m::mock('\Elasticsearch\Transport')
162 162
                          ->shouldReceive('performRequest')->once()
163 163
                          ->with(
164 164
                                  m::any(),
165 165
                                  $uri,
166
-                                 array(),
166
+                                 array (),
167 167
                                  $serializedBody
168 168
                              )
169 169
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +8 added lines, -16 removed lines patch added patch discarded remove patch
@@ -19,8 +19,7 @@  discard block
 block discarded – undo
19 19
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
20 20
  * @link    http://elasticsearch.org
21 21
  */
22
-class MsearchTest extends \PHPUnit_Framework_TestCase
23
-{
22
+class MsearchTest extends \PHPUnit_Framework_TestCase {
24 23
 
25 24
     public function tearDown() {
26 25
         m::close();
@@ -30,8 +29,7 @@  discard block
 block discarded – undo
30 29
     /**
31 30
      * @expectedException RuntimeException
32 31
      */
33
-    public function testGetURIWithNoIndexTypeOrBody()
34
-    {
32
+    public function testGetURIWithNoIndexTypeOrBody() {
35 33
         $mockTransport = m::mock('\Elasticsearch\Transport');
36 34
         $mockSerializer = m::mock('\Elasticsearch\Serializers\ArrayToJSONSerializer');
37 35
 
@@ -40,8 +38,7 @@  discard block
 block discarded – undo
40 38
 
41 39
     }
42 40
 
43
-    public function testGetURIWithNoIndexOrType()
44
-    {
41
+    public function testGetURIWithNoIndexOrType() {
45 42
 
46 43
         $uri = '/_msearch';
47 44
         $body = 'abc';
@@ -61,8 +58,7 @@  discard block
 block discarded – undo
61 58
 
62 59
     }
63 60
 
64
-    public function testGetURIWithIndexButNoType()
65
-    {
61
+    public function testGetURIWithIndexButNoType() {
66 62
         $uri = '/testIndex/_msearch';
67 63
         $body = 'abc';
68 64
         $mockTransport = m::mock('\Elasticsearch\Transport')
@@ -83,8 +79,7 @@  discard block
 block discarded – undo
83 79
 
84 80
     }
85 81
 
86
-    public function testGetURIWithTypeButNoIndex()
87
-    {
82
+    public function testGetURIWithTypeButNoIndex() {
88 83
 
89 84
         $uri = '/_all/testType/_msearch';
90 85
         $body = 'abc';
@@ -106,8 +101,7 @@  discard block
 block discarded – undo
106 101
 
107 102
     }
108 103
 
109
-    public function testGetURIWithBothTypeAndIndex()
110
-    {
104
+    public function testGetURIWithBothTypeAndIndex() {
111 105
 
112 106
         $uri = '/testIndex/testType/_msearch';
113 107
         $body = 'abc';
@@ -131,8 +125,7 @@  discard block
 block discarded – undo
131 125
     }
132 126
 
133 127
 
134
-    public function testValidMsearch()
135
-    {
128
+    public function testValidMsearch() {
136 129
         $body = 'abc';
137 130
         $mockTransport = m::mock('\Elasticsearch\Transport')
138 131
                          ->shouldReceive('performRequest')->once()
@@ -153,8 +146,7 @@  discard block
 block discarded – undo
153 146
 
154 147
     }
155 148
 
156
-    public function testSerializeArrayBody()
157
-    {
149
+    public function testSerializeArrayBody() {
158 150
         $uri = '/_msearch';
159 151
         $body = array(array('query'=>array('match_all' => array())),array('query'=>array('match_all' => array())));
160 152
         $serializedBody = json_encode($body[0])."\n".json_encode($body[1])."\n";
Please login to merge, or discard this patch.
tests/Elasticsearch/Tests/Endpoints/AbstractEndpointTest.php 4 patches
Indentation   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -29,14 +29,14 @@  discard block
 block discarded – undo
29 29
     public function testPerformRequest()
30 30
     {
31 31
         $mockTransport = m::mock('\Elasticsearch\Transport')
32
-                         ->shouldReceive('performRequest')->once()->once()
33
-                         ->with(
34
-                                 'GET',
35
-                                 '/testIndex/',
36
-                                 array(),
37
-                                 null
38
-                             )
39
-                         ->getMock();
32
+                            ->shouldReceive('performRequest')->once()->once()
33
+                            ->with(
34
+                                    'GET',
35
+                                    '/testIndex/',
36
+                                    array(),
37
+                                    null
38
+                                )
39
+                            ->getMock();
40 40
 
41 41
         $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
42 42
 
@@ -138,14 +138,14 @@  discard block
 block discarded – undo
138 138
         );
139 139
 
140 140
         $mockTransport = m::mock('\Elasticsearch\Transport')
141
-                         ->shouldReceive('performRequest')->once()->once()
142
-                         ->with(
143
-                                 'GET',
144
-                                 '/testIndex/',
145
-                                 $params,
146
-                                 null
147
-                             )
148
-                         ->getMock();
141
+                            ->shouldReceive('performRequest')->once()->once()
142
+                            ->with(
143
+                                    'GET',
144
+                                    '/testIndex/',
145
+                                    $params,
146
+                                    null
147
+                                )
148
+                            ->getMock();
149 149
 
150 150
 
151 151
         $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
@@ -157,16 +157,16 @@  discard block
 block discarded – undo
157 157
         );
158 158
 
159 159
         $stub->expects($this->once())
160
-             ->method('getParamWhitelist')
161
-             ->will($this->returnValue($paramWhiteList));
160
+                ->method('getParamWhitelist')
161
+                ->will($this->returnValue($paramWhiteList));
162 162
 
163 163
         $stub->expects($this->once())
164
-             ->method('getURI')
165
-             ->will($this->returnValue('/testIndex/'));
164
+                ->method('getURI')
165
+                ->will($this->returnValue('/testIndex/'));
166 166
 
167 167
         $stub->expects($this->once())
168
-             ->method('getMethod')
169
-             ->will($this->returnValue('GET'));
168
+                ->method('getMethod')
169
+                ->will($this->returnValue('GET'));
170 170
 
171 171
         /** @var AbstractEndpoint $stub */
172 172
         $stub->setParams($params);
@@ -206,14 +206,14 @@  discard block
 block discarded – undo
206 206
         );
207 207
 
208 208
         $mockTransport = m::mock('\Elasticsearch\Transport')
209
-                         ->shouldReceive('performRequest')->once()->once()
210
-                         ->with(
211
-                                 'GET',
212
-                                 '/testIndex/',
213
-                                 $expected,
214
-                                 null
215
-                             )
216
-                         ->getMock();
209
+                            ->shouldReceive('performRequest')->once()->once()
210
+                            ->with(
211
+                                    'GET',
212
+                                    '/testIndex/',
213
+                                    $expected,
214
+                                    null
215
+                                )
216
+                            ->getMock();
217 217
 
218 218
 
219 219
         $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
Please login to merge, or discard this patch.
Spacing   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -33,12 +33,12 @@  discard block
 block discarded – undo
33 33
                          ->with(
34 34
                                  'GET',
35 35
                                  '/testIndex/',
36
-                                 array(),
36
+                                 array (),
37 37
                                  null
38 38
                              )
39 39
                          ->getMock();
40 40
 
41
-        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
41
+        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array ($mockTransport));
42 42
 
43 43
         $stub->expects($this->once())
44 44
             ->method('getURI')
@@ -56,9 +56,9 @@  discard block
 block discarded – undo
56 56
     {
57 57
         $mockTransport = m::mock('\Elasticsearch\Transport');
58 58
 
59
-        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
59
+        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array ($mockTransport));
60 60
 
61
-        $paramWhiteList = array(
61
+        $paramWhiteList = array (
62 62
             'param1',
63 63
             'param2',
64 64
             'param3'
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
             ->will($this->returnValue($paramWhiteList));
70 70
 
71 71
 
72
-        $params = array('param1'=>'value');
72
+        $params = array ('param1'=>'value');
73 73
         $stub->setParams($params);
74 74
 
75 75
     }
@@ -78,9 +78,9 @@  discard block
 block discarded – undo
78 78
     {
79 79
         $mockTransport = m::mock('\Elasticsearch\Transport');
80 80
 
81
-        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
81
+        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array ($mockTransport));
82 82
 
83
-        $paramWhiteList = array(
83
+        $paramWhiteList = array (
84 84
             'param1',
85 85
             'param2',
86 86
             'param3'
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
         ->method('getParamWhitelist')
91 91
         ->will($this->returnValue($paramWhiteList));
92 92
 
93
-        $params = array(
93
+        $params = array (
94 94
             'param1' => 'value',
95 95
             'param2' => 'value',
96 96
             'param3' => 'value'
@@ -107,9 +107,9 @@  discard block
 block discarded – undo
107 107
     {
108 108
         $mockTransport = m::mock('\Elasticsearch\Transport');
109 109
 
110
-        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
110
+        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array ($mockTransport));
111 111
 
112
-        $paramWhiteList = array(
112
+        $paramWhiteList = array (
113 113
             'param1',
114 114
             'param2',
115 115
             'param3'
@@ -119,17 +119,17 @@  discard block
 block discarded – undo
119 119
         ->method('getParamWhitelist')
120 120
         ->will($this->returnValue($paramWhiteList));
121 121
 
122
-        $params = array('param10' => 'value');
122
+        $params = array ('param10' => 'value');
123 123
         $stub->setParams($params);
124 124
 
125 125
     }
126 126
 
127 127
     public function testSetSortParam()
128 128
     {
129
-        $params = array(
130
-            'sort' => array(
129
+        $params = array (
130
+            'sort' => array (
131 131
                 'field' => 'value2',
132
-                'field2' => array(
132
+                'field2' => array (
133 133
                     'field3' => 'value3'
134 134
                 )
135 135
             ),
@@ -148,9 +148,9 @@  discard block
 block discarded – undo
148 148
                          ->getMock();
149 149
 
150 150
 
151
-        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
151
+        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array ($mockTransport));
152 152
 
153
-        $paramWhiteList = array(
153
+        $paramWhiteList = array (
154 154
             'sort',
155 155
             'param2',
156 156
             'param3'
@@ -180,24 +180,24 @@  discard block
 block discarded – undo
180 180
 
181 181
     public function testSetSortParamWithImplodeList()
182 182
     {
183
-        $params = array(
184
-            'sort' => array(
183
+        $params = array (
184
+            'sort' => array (
185 185
                 'field' => 'value2',
186
-                'field2' => array(
186
+                'field2' => array (
187 187
                     'field3' => 'value3'
188 188
                 )
189 189
             ),
190
-            'param2' => array(
190
+            'param2' => array (
191 191
                 'implode1',
192 192
                 'implode2'
193 193
             ),
194 194
             'param3' => 'value'
195 195
         );
196 196
 
197
-        $expected = array(
198
-            'sort' => array(
197
+        $expected = array (
198
+            'sort' => array (
199 199
                 'field' => 'value2',
200
-                'field2' => array(
200
+                'field2' => array (
201 201
                     'field3' => 'value3'
202 202
                 )
203 203
             ),
@@ -216,9 +216,9 @@  discard block
 block discarded – undo
216 216
                          ->getMock();
217 217
 
218 218
 
219
-        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
219
+        $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array ($mockTransport));
220 220
 
221
-        $paramWhiteList = array(
221
+        $paramWhiteList = array (
222 222
             'sort',
223 223
             'param2',
224 224
             'param3'
Please login to merge, or discard this patch.
Braces   +7 added lines, -14 removed lines patch added patch discarded remove patch
@@ -19,15 +19,13 @@  discard block
 block discarded – undo
19 19
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
20 20
  * @link    http://elasticsearch.org
21 21
  */
22
-class AbstractEndpointTest extends \PHPUnit_Framework_TestCase
23
-{
22
+class AbstractEndpointTest extends \PHPUnit_Framework_TestCase {
24 23
 
25 24
     public function tearDown() {
26 25
         m::close();
27 26
     }
28 27
 
29
-    public function testPerformRequest()
30
-    {
28
+    public function testPerformRequest() {
31 29
         $mockTransport = m::mock('\Elasticsearch\Transport')
32 30
                          ->shouldReceive('performRequest')->once()->once()
33 31
                          ->with(
@@ -52,8 +50,7 @@  discard block
 block discarded – undo
52 50
 
53 51
     }
54 52
 
55
-    public function testSetOneParam()
56
-    {
53
+    public function testSetOneParam() {
57 54
         $mockTransport = m::mock('\Elasticsearch\Transport');
58 55
 
59 56
         $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
@@ -74,8 +71,7 @@  discard block
 block discarded – undo
74 71
 
75 72
     }
76 73
 
77
-    public function testSetMultipleParam()
78
-    {
74
+    public function testSetMultipleParam() {
79 75
         $mockTransport = m::mock('\Elasticsearch\Transport');
80 76
 
81 77
         $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
@@ -103,8 +99,7 @@  discard block
 block discarded – undo
103 99
     /**
104 100
      * @expectedException UnexpectedValueException
105 101
      */
106
-    public function testSetInvalidParam()
107
-    {
102
+    public function testSetInvalidParam() {
108 103
         $mockTransport = m::mock('\Elasticsearch\Transport');
109 104
 
110 105
         $stub = $this->getMockForAbstractClass('\Elasticsearch\Endpoints\AbstractEndpoint', array($mockTransport));
@@ -124,8 +119,7 @@  discard block
 block discarded – undo
124 119
 
125 120
     }
126 121
 
127
-    public function testSetSortParam()
128
-    {
122
+    public function testSetSortParam() {
129 123
         $params = array(
130 124
             'sort' => array(
131 125
                 'field' => 'value2',
@@ -178,8 +172,7 @@  discard block
 block discarded – undo
178 172
         }
179 173
     }
180 174
 
181
-    public function testSetSortParamWithImplodeList()
182
-    {
175
+    public function testSetSortParamWithImplodeList() {
183 176
         $params = array(
184 177
             'sort' => array(
185 178
                 'field' => 'value2',
Please login to merge, or discard this patch.
Upper-Lower-Casing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
                                  'GET',
35 35
                                  '/testIndex/',
36 36
                                  array(),
37
-                                 null
37
+                                 NULL
38 38
                              )
39 39
                          ->getMock();
40 40
 
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
                                  'GET',
144 144
                                  '/testIndex/',
145 145
                                  $params,
146
-                                 null
146
+                                 NULL
147 147
                              )
148 148
                          ->getMock();
149 149
 
@@ -211,7 +211,7 @@  discard block
 block discarded – undo
211 211
                                  'GET',
212 212
                                  '/testIndex/',
213 213
                                  $expected,
214
-                                 null
214
+                                 NULL
215 215
                              )
216 216
                          ->getMock();
217 217
 
Please login to merge, or discard this patch.
ElasticSearchPhpClient/tests/Elasticsearch/Tests/Endpoints/UpdateTest.php 4 patches
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -80,14 +80,14 @@
 block discarded – undo
80 80
     public function testValidUpdate()
81 81
     {
82 82
         $mockTransport = m::mock('\Elasticsearch\Transport')
83
-                         ->shouldReceive('performRequest')->once()
84
-                         ->with(
85
-                                 'POST',
86
-                                 '/testIndex/testType/testID/_update',
87
-                                 array(),
88
-                                 null
89
-                             )
90
-                         ->getMock();
83
+                            ->shouldReceive('performRequest')->once()
84
+                            ->with(
85
+                                    'POST',
86
+                                    '/testIndex/testType/testID/_update',
87
+                                    array(),
88
+                                    null
89
+                                )
90
+                            ->getMock();
91 91
 
92 92
         $action = new Update($mockTransport);
93 93
         $action->setIndex('testIndex')
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -84,7 +84,7 @@
 block discarded – undo
84 84
                          ->with(
85 85
                                  'POST',
86 86
                                  '/testIndex/testType/testID/_update',
87
-                                 array(),
87
+                                 array (),
88 88
                                  null
89 89
                              )
90 90
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +6 added lines, -12 removed lines patch added patch discarded remove patch
@@ -18,8 +18,7 @@  discard block
 block discarded – undo
18 18
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
19 19
  * @link    http://elasticsearch.org
20 20
  */
21
-class UpdateTest extends \PHPUnit_Framework_TestCase
22
-{
21
+class UpdateTest extends \PHPUnit_Framework_TestCase {
23 22
     public function tearDown() {
24 23
         m::close();
25 24
     }
@@ -28,8 +27,7 @@  discard block
 block discarded – undo
28 27
     /**
29 28
      * @expectedException RuntimeException
30 29
      */
31
-    public function testNoIndexTypeOrID()
32
-    {
30
+    public function testNoIndexTypeOrID() {
33 31
 
34 32
         $mockTransport = m::mock('\Elasticsearch\Transport');
35 33
 
@@ -41,8 +39,7 @@  discard block
 block discarded – undo
41 39
     /**
42 40
      * @expectedException RuntimeException
43 41
      */
44
-    public function testNoIndex()
45
-    {
42
+    public function testNoIndex() {
46 43
 
47 44
         $mockTransport = m::mock('\Elasticsearch\Transport');
48 45
 
@@ -54,8 +51,7 @@  discard block
 block discarded – undo
54 51
     /**
55 52
      * @expectedException RuntimeException
56 53
      */
57
-    public function testNoType()
58
-    {
54
+    public function testNoType() {
59 55
 
60 56
         $mockTransport = m::mock('\Elasticsearch\Transport');
61 57
 
@@ -67,8 +63,7 @@  discard block
 block discarded – undo
67 63
     /**
68 64
      * @expectedException RuntimeException
69 65
      */
70
-    public function testNoID()
71
-    {
66
+    public function testNoID() {
72 67
 
73 68
         $mockTransport = m::mock('\Elasticsearch\Transport');
74 69
 
@@ -77,8 +72,7 @@  discard block
 block discarded – undo
77 72
 
78 73
     }
79 74
 
80
-    public function testValidUpdate()
81
-    {
75
+    public function testValidUpdate() {
82 76
         $mockTransport = m::mock('\Elasticsearch\Transport')
83 77
                          ->shouldReceive('performRequest')->once()
84 78
                          ->with(
Please login to merge, or discard this patch.
Upper-Lower-Casing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@
 block discarded – undo
85 85
                                  'POST',
86 86
                                  '/testIndex/testType/testID/_update',
87 87
                                  array(),
88
-                                 null
88
+                                 NULL
89 89
                              )
90 90
                          ->getMock();
91 91
 
Please login to merge, or discard this patch.
Lib/ElasticSearchPhpClient/tests/Elasticsearch/Tests/Endpoints/GetTest.php 4 patches
Indentation   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -81,14 +81,14 @@  discard block
 block discarded – undo
81 81
     {
82 82
 
83 83
         $mockTransport = m::mock('\Elasticsearch\Transport')
84
-                         ->shouldReceive('performRequest')->once()
85
-                         ->with(
86
-                                 'GET',
87
-                                 '/testIndex/testType/abc',
88
-                                 array(),
89
-                                 null
90
-                             )
91
-                         ->getMock();
84
+                            ->shouldReceive('performRequest')->once()
85
+                            ->with(
86
+                                    'GET',
87
+                                    '/testIndex/testType/abc',
88
+                                    array(),
89
+                                    null
90
+                                )
91
+                            ->getMock();
92 92
 
93 93
 
94 94
 
@@ -103,14 +103,14 @@  discard block
 block discarded – undo
103 103
     public function testValidIndexWithSourceOnly()
104 104
     {
105 105
         $mockTransport = m::mock('\Elasticsearch\Transport')
106
-                         ->shouldReceive('performRequest')->once()
107
-                         ->with(
108
-                                 'GET',
109
-                                 '/testIndex/testType/abc/_source',
110
-                                 array(),
111
-                                 null
112
-                             )
113
-                         ->getMock();
106
+                            ->shouldReceive('performRequest')->once()
107
+                            ->with(
108
+                                    'GET',
109
+                                    '/testIndex/testType/abc/_source',
110
+                                    array(),
111
+                                    null
112
+                                )
113
+                            ->getMock();
114 114
 
115 115
 
116 116
 
@@ -126,14 +126,14 @@  discard block
 block discarded – undo
126 126
     public function testValidIndexWithExistenceOnly()
127 127
     {
128 128
         $mockTransport = m::mock('\Elasticsearch\Transport')
129
-                         ->shouldReceive('performRequest')->once()
130
-                         ->with(
131
-                                 'HEAD',
132
-                                 '/testIndex/testType/abc',
133
-                                 array(),
134
-                                 null
135
-                             )
136
-                         ->getMock();
129
+                            ->shouldReceive('performRequest')->once()
130
+                            ->with(
131
+                                    'HEAD',
132
+                                    '/testIndex/testType/abc',
133
+                                    array(),
134
+                                    null
135
+                                )
136
+                            ->getMock();
137 137
 
138 138
 
139 139
 
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
                          ->with(
86 86
                                  'GET',
87 87
                                  '/testIndex/testType/abc',
88
-                                 array(),
88
+                                 array (),
89 89
                                  null
90 90
                              )
91 91
                          ->getMock();
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
                          ->with(
108 108
                                  'GET',
109 109
                                  '/testIndex/testType/abc/_source',
110
-                                 array(),
110
+                                 array (),
111 111
                                  null
112 112
                              )
113 113
                          ->getMock();
@@ -130,7 +130,7 @@  discard block
 block discarded – undo
130 130
                          ->with(
131 131
                                  'HEAD',
132 132
                                  '/testIndex/testType/abc',
133
-                                 array(),
133
+                                 array (),
134 134
                                  null
135 135
                              )
136 136
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +8 added lines, -16 removed lines patch added patch discarded remove patch
@@ -18,8 +18,7 @@  discard block
 block discarded – undo
18 18
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
19 19
  * @link    http://elasticsearch.org
20 20
  */
21
-class GetTest extends \PHPUnit_Framework_TestCase
22
-{
21
+class GetTest extends \PHPUnit_Framework_TestCase {
23 22
     public function tearDown() {
24 23
         m::close();
25 24
     }
@@ -28,8 +27,7 @@  discard block
 block discarded – undo
28 27
     /**
29 28
      * @expectedException RuntimeException
30 29
      */
31
-    public function testNoIndexTypeOrID()
32
-    {
30
+    public function testNoIndexTypeOrID() {
33 31
 
34 32
         $mockTransport = m::mock('\Elasticsearch\Transport');
35 33
 
@@ -41,8 +39,7 @@  discard block
 block discarded – undo
41 39
     /**
42 40
      * @expectedException RuntimeException
43 41
      */
44
-    public function testNoIndex()
45
-    {
42
+    public function testNoIndex() {
46 43
 
47 44
         $mockTransport = m::mock('\Elasticsearch\Transport');
48 45
 
@@ -54,8 +51,7 @@  discard block
 block discarded – undo
54 51
     /**
55 52
      * @expectedException RuntimeException
56 53
      */
57
-    public function testNoType()
58
-    {
54
+    public function testNoType() {
59 55
 
60 56
         $mockTransport = m::mock('\Elasticsearch\Transport');
61 57
 
@@ -67,8 +63,7 @@  discard block
 block discarded – undo
67 63
     /**
68 64
      * @expectedException RuntimeException
69 65
      */
70
-    public function testNoID()
71
-    {
66
+    public function testNoID() {
72 67
 
73 68
         $mockTransport = m::mock('\Elasticsearch\Transport');
74 69
 
@@ -77,8 +72,7 @@  discard block
 block discarded – undo
77 72
 
78 73
     }
79 74
 
80
-    public function testValidGet()
81
-    {
75
+    public function testValidGet() {
82 76
 
83 77
         $mockTransport = m::mock('\Elasticsearch\Transport')
84 78
                          ->shouldReceive('performRequest')->once()
@@ -100,8 +94,7 @@  discard block
 block discarded – undo
100 94
 
101 95
     }
102 96
 
103
-    public function testValidIndexWithSourceOnly()
104
-    {
97
+    public function testValidIndexWithSourceOnly() {
105 98
         $mockTransport = m::mock('\Elasticsearch\Transport')
106 99
                          ->shouldReceive('performRequest')->once()
107 100
                          ->with(
@@ -123,8 +116,7 @@  discard block
 block discarded – undo
123 116
 
124 117
     }
125 118
 
126
-    public function testValidIndexWithExistenceOnly()
127
-    {
119
+    public function testValidIndexWithExistenceOnly() {
128 120
         $mockTransport = m::mock('\Elasticsearch\Transport')
129 121
                          ->shouldReceive('performRequest')->once()
130 122
                          ->with(
Please login to merge, or discard this patch.
Upper-Lower-Casing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
                                  'GET',
87 87
                                  '/testIndex/testType/abc',
88 88
                                  array(),
89
-                                 null
89
+                                 NULL
90 90
                              )
91 91
                          ->getMock();
92 92
 
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
                                  'GET',
109 109
                                  '/testIndex/testType/abc/_source',
110 110
                                  array(),
111
-                                 null
111
+                                 NULL
112 112
                              )
113 113
                          ->getMock();
114 114
 
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
                                  'HEAD',
132 132
                                  '/testIndex/testType/abc',
133 133
                                  array(),
134
-                                 null
134
+                                 NULL
135 135
                              )
136 136
                          ->getMock();
137 137
 
Please login to merge, or discard this patch.
ElasticSearchPhpClient/tests/Elasticsearch/Tests/Endpoints/ScrollTest.php 3 patches
Indentation   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -45,14 +45,14 @@  discard block
 block discarded – undo
45 45
         $uri = '/_search/scroll';
46 46
 
47 47
         $mockTransport = m::mock('\Elasticsearch\Transport')
48
-                         ->shouldReceive('performRequest')->once()
49
-                         ->with(
50
-                                 'GET',
51
-                                 $uri,
52
-                                 array(),
53
-                                 $body
54
-                             )
55
-                         ->getMock();
48
+                            ->shouldReceive('performRequest')->once()
49
+                            ->with(
50
+                                    'GET',
51
+                                    $uri,
52
+                                    array(),
53
+                                    $body
54
+                                )
55
+                            ->getMock();
56 56
 
57 57
 
58 58
 
@@ -68,14 +68,14 @@  discard block
 block discarded – undo
68 68
         $uri = "/_search/scroll/$body";
69 69
 
70 70
         $mockTransport = m::mock('\Elasticsearch\Transport')
71
-                         ->shouldReceive('performRequest')->once()
72
-                         ->with(
73
-                                 'GET',
74
-                                 $uri,
75
-                                 array(),
76
-                                 $body
77
-                             )
78
-                         ->getMock();
71
+                            ->shouldReceive('performRequest')->once()
72
+                            ->with(
73
+                                    'GET',
74
+                                    $uri,
75
+                                    array(),
76
+                                    $body
77
+                                )
78
+                            ->getMock();
79 79
 
80 80
 
81 81
 
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
                          ->with(
50 50
                                  'GET',
51 51
                                  $uri,
52
-                                 array(),
52
+                                 array (),
53 53
                                  $body
54 54
                              )
55 55
                          ->getMock();
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
                          ->with(
73 73
                                  'GET',
74 74
                                  $uri,
75
-                                 array(),
75
+                                 array (),
76 76
                                  $body
77 77
                              )
78 78
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,15 +19,13 @@  discard block
 block discarded – undo
19 19
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
20 20
  * @link    http://Elasticsearch.org
21 21
  */
22
-class ScrollTest extends \PHPUnit_Framework_TestCase
23
-{
22
+class ScrollTest extends \PHPUnit_Framework_TestCase {
24 23
 
25 24
     public function tearDown() {
26 25
         m::close();
27 26
     }
28 27
 
29
-    public function testSetStringBody()
30
-    {
28
+    public function testSetStringBody() {
31 29
         $body = 'scrollid';
32 30
 
33 31
         $mockTransport = m::mock('\Elasticsearch\Transport');
@@ -39,8 +37,7 @@  discard block
 block discarded – undo
39 37
     }
40 38
 
41 39
 
42
-    public function testWithBodyNoScrollID()
43
-    {
40
+    public function testWithBodyNoScrollID() {
44 41
         $body = 'scrollID';
45 42
         $uri = '/_search/scroll';
46 43
 
@@ -62,8 +59,7 @@  discard block
 block discarded – undo
62 59
 
63 60
     }
64 61
 
65
-    public function testWithBodyAndScrollID()
66
-    {
62
+    public function testWithBodyAndScrollID() {
67 63
         $body = 'scrollID';
68 64
         $uri = "/_search/scroll/$body";
69 65
 
Please login to merge, or discard this patch.
ElasticSearchPhpClient/tests/Elasticsearch/Tests/Endpoints/ExplainTest.php 4 patches
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -80,14 +80,14 @@
 block discarded – undo
80 80
     public function testValidExplain()
81 81
     {
82 82
         $mockTransport = m::mock('\Elasticsearch\Transport')
83
-                         ->shouldReceive('performRequest')->once()
84
-                         ->with(
85
-                                 'GET',
86
-                                 '/testIndex/testType/testID/_explain',
87
-                                 array(),
88
-                                 null
89
-                             )
90
-                         ->getMock();
83
+                            ->shouldReceive('performRequest')->once()
84
+                            ->with(
85
+                                    'GET',
86
+                                    '/testIndex/testType/testID/_explain',
87
+                                    array(),
88
+                                    null
89
+                                )
90
+                            ->getMock();
91 91
 
92 92
         $action = new Explain($mockTransport);
93 93
         $action->setIndex('testIndex')
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -84,7 +84,7 @@
 block discarded – undo
84 84
                          ->with(
85 85
                                  'GET',
86 86
                                  '/testIndex/testType/testID/_explain',
87
-                                 array(),
87
+                                 array (),
88 88
                                  null
89 89
                              )
90 90
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +6 added lines, -12 removed lines patch added patch discarded remove patch
@@ -18,8 +18,7 @@  discard block
 block discarded – undo
18 18
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
19 19
  * @link    http://elasticsearch.org
20 20
  */
21
-class ExplainTest extends \PHPUnit_Framework_TestCase
22
-{
21
+class ExplainTest extends \PHPUnit_Framework_TestCase {
23 22
     public function tearDown() {
24 23
         m::close();
25 24
     }
@@ -28,8 +27,7 @@  discard block
 block discarded – undo
28 27
     /**
29 28
      * @expectedException RuntimeException
30 29
      */
31
-    public function testNoIndexTypeOrID()
32
-    {
30
+    public function testNoIndexTypeOrID() {
33 31
 
34 32
         $mockTransport = m::mock('\Elasticsearch\Transport');
35 33
 
@@ -41,8 +39,7 @@  discard block
 block discarded – undo
41 39
     /**
42 40
      * @expectedException RuntimeException
43 41
      */
44
-    public function testNoIndex()
45
-    {
42
+    public function testNoIndex() {
46 43
 
47 44
         $mockTransport = m::mock('\Elasticsearch\Transport');
48 45
 
@@ -54,8 +51,7 @@  discard block
 block discarded – undo
54 51
     /**
55 52
      * @expectedException RuntimeException
56 53
      */
57
-    public function testNoType()
58
-    {
54
+    public function testNoType() {
59 55
 
60 56
         $mockTransport = m::mock('\Elasticsearch\Transport');
61 57
 
@@ -67,8 +63,7 @@  discard block
 block discarded – undo
67 63
     /**
68 64
      * @expectedException RuntimeException
69 65
      */
70
-    public function testNoID()
71
-    {
66
+    public function testNoID() {
72 67
 
73 68
         $mockTransport = m::mock('\Elasticsearch\Transport');
74 69
 
@@ -77,8 +72,7 @@  discard block
 block discarded – undo
77 72
 
78 73
     }
79 74
 
80
-    public function testValidExplain()
81
-    {
75
+    public function testValidExplain() {
82 76
         $mockTransport = m::mock('\Elasticsearch\Transport')
83 77
                          ->shouldReceive('performRequest')->once()
84 78
                          ->with(
Please login to merge, or discard this patch.
Upper-Lower-Casing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@
 block discarded – undo
85 85
                                  'GET',
86 86
                                  '/testIndex/testType/testID/_explain',
87 87
                                  array(),
88
-                                 null
88
+                                 NULL
89 89
                              )
90 90
                          ->getMock();
91 91
 
Please login to merge, or discard this patch.
tests/Elasticsearch/Tests/Endpoints/Indices/DeleteTest.php 4 patches
Indentation   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -27,14 +27,14 @@  discard block
 block discarded – undo
27 27
     {
28 28
 
29 29
         $mockTransport = m::mock('\Elasticsearch\Transport')
30
-                         ->shouldReceive('performRequest')->once()
31
-                         ->with(
32
-                                 'DELETE',
33
-                                 '/',
34
-                                 array(),
35
-                                 null
36
-                             )
37
-                         ->getMock();
30
+                            ->shouldReceive('performRequest')->once()
31
+                            ->with(
32
+                                    'DELETE',
33
+                                    '/',
34
+                                    array(),
35
+                                    null
36
+                                )
37
+                            ->getMock();
38 38
 
39 39
         $action = new Delete($mockTransport);
40 40
         $action->performRequest();
@@ -45,14 +45,14 @@  discard block
 block discarded – undo
45 45
     {
46 46
 
47 47
         $mockTransport = m::mock('\Elasticsearch\Transport')
48
-                         ->shouldReceive('performRequest')->once()
49
-                         ->with(
50
-                                 'DELETE',
51
-                                 '/testIndex',
52
-                                 array(),
53
-                                 null
54
-                             )
55
-                         ->getMock();
48
+                            ->shouldReceive('performRequest')->once()
49
+                            ->with(
50
+                                    'DELETE',
51
+                                    '/testIndex',
52
+                                    array(),
53
+                                    null
54
+                                )
55
+                            ->getMock();
56 56
 
57 57
         $action = new Delete($mockTransport);
58 58
         $action->setIndex('testIndex')
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
                          ->with(
32 32
                                  'DELETE',
33 33
                                  '/',
34
-                                 array(),
34
+                                 array (),
35 35
                                  null
36 36
                              )
37 37
                          ->getMock();
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
                          ->with(
50 50
                                  'DELETE',
51 51
                                  '/testIndex',
52
-                                 array(),
52
+                                 array (),
53 53
                                  null
54 54
                              )
55 55
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -17,14 +17,12 @@  discard block
 block discarded – undo
17 17
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
18 18
  * @link    http://elasticsearch.org
19 19
  */
20
-class DeleteTest extends \PHPUnit_Framework_TestCase
21
-{
20
+class DeleteTest extends \PHPUnit_Framework_TestCase {
22 21
     public function tearDown() {
23 22
         m::close();
24 23
     }
25 24
 
26
-    public function testValidDeleteWithNoIndex()
27
-    {
25
+    public function testValidDeleteWithNoIndex() {
28 26
 
29 27
         $mockTransport = m::mock('\Elasticsearch\Transport')
30 28
                          ->shouldReceive('performRequest')->once()
@@ -41,8 +39,7 @@  discard block
 block discarded – undo
41 39
 
42 40
     }
43 41
 
44
-    public function testValidDeleteWithIndex()
45
-    {
42
+    public function testValidDeleteWithIndex() {
46 43
 
47 44
         $mockTransport = m::mock('\Elasticsearch\Transport')
48 45
                          ->shouldReceive('performRequest')->once()
Please login to merge, or discard this patch.
Upper-Lower-Casing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
                                  'DELETE',
33 33
                                  '/',
34 34
                                  array(),
35
-                                 null
35
+                                 NULL
36 36
                              )
37 37
                          ->getMock();
38 38
 
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
                                  'DELETE',
51 51
                                  '/testIndex',
52 52
                                  array(),
53
-                                 null
53
+                                 NULL
54 54
                              )
55 55
                          ->getMock();
56 56
 
Please login to merge, or discard this patch.
tests/Elasticsearch/Tests/Endpoints/Indices/OpenTest.php 4 patches
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -41,14 +41,14 @@
 block discarded – undo
41 41
     {
42 42
 
43 43
         $mockTransport = m::mock('\Elasticsearch\Transport')
44
-                         ->shouldReceive('performRequest')->once()
45
-                         ->with(
46
-                                 'POST',
47
-                                 '/testIndex/_open',
48
-                                 array(),
49
-                                 null
50
-                             )
51
-                         ->getMock();
44
+                            ->shouldReceive('performRequest')->once()
45
+                            ->with(
46
+                                    'POST',
47
+                                    '/testIndex/_open',
48
+                                    array(),
49
+                                    null
50
+                                )
51
+                            ->getMock();
52 52
 
53 53
 
54 54
 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
                          ->with(
46 46
                                  'POST',
47 47
                                  '/testIndex/_open',
48
-                                 array(),
48
+                                 array (),
49 49
                                  null
50 50
                              )
51 51
                          ->getMock();
Please login to merge, or discard this patch.
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -18,8 +18,7 @@  discard block
 block discarded – undo
18 18
  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache2
19 19
  * @link    http://elasticsearch.org
20 20
  */
21
-class OpenTest extends \PHPUnit_Framework_TestCase
22
-{
21
+class OpenTest extends \PHPUnit_Framework_TestCase {
23 22
     public function tearDown() {
24 23
         m::close();
25 24
     }
@@ -27,8 +26,7 @@  discard block
 block discarded – undo
27 26
     /**
28 27
      * @expectedException RuntimeException
29 28
      */
30
-    public function testNoIndex()
31
-    {
29
+    public function testNoIndex() {
32 30
 
33 31
         $mockTransport = m::mock('\Elasticsearch\Transport');
34 32
 
@@ -37,8 +35,7 @@  discard block
 block discarded – undo
37 35
 
38 36
     }
39 37
 
40
-    public function testValidOpen()
41
-    {
38
+    public function testValidOpen() {
42 39
 
43 40
         $mockTransport = m::mock('\Elasticsearch\Transport')
44 41
                          ->shouldReceive('performRequest')->once()
Please login to merge, or discard this patch.
Upper-Lower-Casing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
                                  'POST',
47 47
                                  '/testIndex/_open',
48 48
                                  array(),
49
-                                 null
49
+                                 NULL
50 50
                              )
51 51
                          ->getMock();
52 52
 
Please login to merge, or discard this patch.