44 * @license GNU General Public License version 2 or later; see LICENSE
55 */
66
7- namespace Joomla \Github \Tests ;
7+ namespace Joomla \Github \Tests \ Package \ Repositories ;
88
99use Joomla \Github \Package \Repositories \Releases ;
1010use Joomla \Github \Tests \Stub \GitHubTestCase ;
@@ -96,7 +96,7 @@ public function testCreateFailure()
9696 ->with ('/repos/joomla/joomla-platform/releases ' , $ data , [], 0 )
9797 ->willReturn ($ this ->response );
9898
99- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
99+ $ response = json_decode (( string ) $ this ->response ->getBody ());
100100
101101 $ this ->assertEquals (
102102 $ response ,
@@ -120,7 +120,7 @@ public function testEdit()
120120
121121 ->willReturn ($ this ->response );
122122
123- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
123+ $ response = json_decode (( string ) $ this ->response ->getBody ());
124124
125125 $ this ->assertEquals (
126126 $ response ,
@@ -139,7 +139,7 @@ public function testGetList()
139139
140140 $ releases = [];
141141
142- foreach (json_decode ($ this ->response ->getBody ()-> getContents ()) as $ i => $ release ) {
142+ foreach (json_decode (( string ) $ this ->response ->getBody ()) as $ i => $ release ) {
143143 $ releases [$ i + 1 ] = $ release ;
144144 }
145145
@@ -148,7 +148,7 @@ public function testGetList()
148148 ->with ('/repos/joomla/joomla-platform/releases ' , [], 0 )
149149 ->willReturn ($ this ->response );
150150
151- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
151+ $ response = json_decode (( string ) $ this ->response ->getBody ());
152152
153153 $ this ->assertEquals (
154154 $ releases ,
@@ -170,7 +170,7 @@ public function testDelete()
170170 ->with ('/repos/joomla/joomla-platform/releases/123 ' )
171171 ->willReturn ($ this ->response );
172172
173- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
173+ $ response = json_decode (( string ) $ this ->response ->getBody ());
174174
175175 $ this ->assertEquals (
176176 $ response ,
@@ -194,7 +194,7 @@ public function testGetLatest()
194194 ->with ('/repos/joomla/joomla-platform/releases/latest ' , [], 0 )
195195 ->willReturn ($ this ->response );
196196
197- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
197+ $ response = json_decode (( string ) $ this ->response ->getBody ());
198198
199199 $ this ->assertEquals (
200200 $ response ,
@@ -214,7 +214,7 @@ public function testGetByTag()
214214 ->with ('/repos/joomla/joomla-platform/releases/tags/{tag} ' , [], 0 )
215215 ->willReturn ($ this ->response );
216216
217- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
217+ $ response = json_decode (( string ) $ this ->response ->getBody ());
218218
219219 $ this ->assertEquals (
220220 $ response ,
@@ -234,7 +234,7 @@ public function testGetListAssets()
234234 ->with ('/repos/joomla/joomla-platform/releases/123/assets ' , [], 0 )
235235 ->willReturn ($ this ->response );
236236
237- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
237+ $ response = json_decode (( string ) $ this ->response ->getBody ());
238238
239239 $ this ->assertEquals (
240240 $ response ,
@@ -254,7 +254,7 @@ public function testGetAsset()
254254 ->with ('/repos/joomla/joomla-platform/releases/assets/123 ' , [], 0 )
255255 ->willReturn ($ this ->response );
256256
257- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
257+ $ response = json_decode (( string ) $ this ->response ->getBody ());
258258
259259 $ this ->assertEquals (
260260 $ response ,
@@ -276,7 +276,7 @@ public function testEditAsset()
276276 ->with ('/repos/joomla/joomla-platform/releases/assets/123 ' , $ data , [], 0 )
277277 ->willReturn ($ this ->response );
278278
279- $ response = json_decode ($ this ->response ->getBody ()-> getContents ());
279+ $ response = json_decode (( string ) $ this ->response ->getBody ());
280280
281281 $ this ->assertEquals (
282282 $ response ,
0 commit comments