@@ -102,8 +102,8 @@ discard block |
||
102 | 102 | [ |
103 | 103 | IAccountManager::PROPERTY_WEBSITE => $properties[IAccountManager::PROPERTY_WEBSITE], |
104 | 104 | IAccountManager::PROPERTY_PHONE => $properties[IAccountManager::PROPERTY_PHONE], |
105 | - IAccountManager::COLLECTION_EMAIL . '#0' => $additionalProperty1, |
|
106 | - IAccountManager::COLLECTION_EMAIL . '#1' => $additionalProperty2, |
|
105 | + IAccountManager::COLLECTION_EMAIL.'#0' => $additionalProperty1, |
|
106 | + IAccountManager::COLLECTION_EMAIL.'#1' => $additionalProperty2, |
|
107 | 107 | ], |
108 | 108 | $account->getFilteredProperties(IAccountManager::SCOPE_PUBLISHED) |
109 | 109 | ); |
@@ -111,14 +111,14 @@ discard block |
||
111 | 111 | [ |
112 | 112 | IAccountManager::PROPERTY_EMAIL => $properties[IAccountManager::PROPERTY_EMAIL], |
113 | 113 | IAccountManager::PROPERTY_PHONE => $properties[IAccountManager::PROPERTY_PHONE], |
114 | - IAccountManager::COLLECTION_EMAIL . '#0' => $additionalProperty2, |
|
114 | + IAccountManager::COLLECTION_EMAIL.'#0' => $additionalProperty2, |
|
115 | 115 | ], |
116 | 116 | $account->getFilteredProperties(null, IAccountManager::VERIFIED) |
117 | 117 | ); |
118 | 118 | $this->assertEquals( |
119 | 119 | [ |
120 | 120 | IAccountManager::PROPERTY_PHONE => $properties[IAccountManager::PROPERTY_PHONE], |
121 | - IAccountManager::COLLECTION_EMAIL . '#0' => $additionalProperty2, |
|
121 | + IAccountManager::COLLECTION_EMAIL.'#0' => $additionalProperty2, |
|
122 | 122 | ], |
123 | 123 | $account->getFilteredProperties(IAccountManager::SCOPE_PUBLISHED, IAccountManager::VERIFIED), |
124 | 124 | ); |
@@ -22,25 +22,25 @@ |
||
22 | 22 | |
23 | 23 | $mock->expects($this->any()) |
24 | 24 | ->method('set') |
25 | - ->willReturnCallback(function ($key, $value, $ttl) use ($sourceCache) { |
|
25 | + ->willReturnCallback(function($key, $value, $ttl) use ($sourceCache) { |
|
26 | 26 | return $sourceCache->set($key, $value, $ttl); |
27 | 27 | }); |
28 | 28 | |
29 | 29 | $mock->expects($this->any()) |
30 | 30 | ->method('get') |
31 | - ->willReturnCallback(function ($key) use ($sourceCache) { |
|
31 | + ->willReturnCallback(function($key) use ($sourceCache) { |
|
32 | 32 | return $sourceCache->get($key); |
33 | 33 | }); |
34 | 34 | |
35 | 35 | $mock->expects($this->any()) |
36 | 36 | ->method('add') |
37 | - ->willReturnCallback(function ($key, $value, $ttl) use ($sourceCache) { |
|
37 | + ->willReturnCallback(function($key, $value, $ttl) use ($sourceCache) { |
|
38 | 38 | return $sourceCache->add($key, $value, $ttl); |
39 | 39 | }); |
40 | 40 | |
41 | 41 | $mock->expects($this->any()) |
42 | 42 | ->method('remove') |
43 | - ->willReturnCallback(function ($key) use ($sourceCache) { |
|
43 | + ->willReturnCallback(function($key) use ($sourceCache) { |
|
44 | 44 | return $sourceCache->remove($key); |
45 | 45 | }); |
46 | 46 | return $mock; |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | /** |
5 | 5 | * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors |
6 | 6 | * SPDX-FileCopyrightText: 2016 ownCloud, Inc. |
@@ -18,7 +18,7 @@ |
||
18 | 18 | protected function setUp(): void { |
19 | 19 | parent::setUp(); |
20 | 20 | |
21 | - $this->sessionCallback = function () { |
|
21 | + $this->sessionCallback = function() { |
|
22 | 22 | return $this->createMock(ISession::class); |
23 | 23 | }; |
24 | 24 | } |
@@ -102,7 +102,7 @@ |
||
102 | 102 | |
103 | 103 | $this->urlGenerator->expects(self::atLeastOnce()) |
104 | 104 | ->method('getBaseUrl') |
105 | - ->willReturn(self::BASE_URL . $webRoot); |
|
105 | + ->willReturn(self::BASE_URL.$webRoot); |
|
106 | 106 | |
107 | 107 | $result = $this->trait->getTestUrls($url, $isRootRequest); |
108 | 108 | $this->assertEquals($expected, $result); |
@@ -11,7 +11,7 @@ discard block |
||
11 | 11 | protected function setUp(): void { |
12 | 12 | parent::setUp(); |
13 | 13 | |
14 | - require_once \OC::$SERVERROOT . '/lib/private/Template/functions.php'; |
|
14 | + require_once \OC::$SERVERROOT.'/lib/private/Template/functions.php'; |
|
15 | 15 | } |
16 | 16 | |
17 | 17 | public function testPJavaScript(): void { |
@@ -89,13 +89,13 @@ discard block |
||
89 | 89 | public function testRelativeDateToday(): void { |
90 | 90 | $currentTime = 1380703592; |
91 | 91 | $elementTime = $currentTime; |
92 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
92 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
93 | 93 | |
94 | 94 | $this->assertEquals('today', $result); |
95 | 95 | |
96 | 96 | // 2 hours ago is still today |
97 | 97 | $elementTime = $currentTime - 2 * 3600; |
98 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
98 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
99 | 99 | |
100 | 100 | $this->assertEquals('today', $result); |
101 | 101 | } |
@@ -103,13 +103,13 @@ discard block |
||
103 | 103 | public function testRelativeDateYesterday(): void { |
104 | 104 | $currentTime = 1380703592; |
105 | 105 | $elementTime = $currentTime - 24 * 3600; |
106 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
106 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
107 | 107 | |
108 | 108 | $this->assertEquals('yesterday', $result); |
109 | 109 | |
110 | 110 | // yesterday - 2 hours is still yesterday |
111 | 111 | $elementTime = $currentTime - 26 * 3600; |
112 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
112 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
113 | 113 | |
114 | 114 | $this->assertEquals('yesterday', $result); |
115 | 115 | } |
@@ -117,13 +117,13 @@ discard block |
||
117 | 117 | public function testRelativeDate2DaysAgo(): void { |
118 | 118 | $currentTime = 1380703592; |
119 | 119 | $elementTime = $currentTime - 48 * 3600; |
120 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
120 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
121 | 121 | |
122 | 122 | $this->assertEquals('2 days ago', $result); |
123 | 123 | |
124 | 124 | // 2 days ago minus 4 hours is still 2 days ago |
125 | 125 | $elementTime = $currentTime - 52 * 3600; |
126 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
126 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
127 | 127 | |
128 | 128 | $this->assertEquals('2 days ago', $result); |
129 | 129 | } |
@@ -131,12 +131,12 @@ discard block |
||
131 | 131 | public function testRelativeDateLastMonth(): void { |
132 | 132 | $currentTime = 1380703592; |
133 | 133 | $elementTime = $currentTime - 86400 * 31; |
134 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
134 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
135 | 135 | |
136 | 136 | $this->assertEquals('last month', $result); |
137 | 137 | |
138 | 138 | $elementTime = $currentTime - 86400 * 35; |
139 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
139 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
140 | 140 | |
141 | 141 | $this->assertEquals('last month', $result); |
142 | 142 | } |
@@ -144,12 +144,12 @@ discard block |
||
144 | 144 | public function testRelativeDateMonthsAgo(): void { |
145 | 145 | $currentTime = 1380703592; |
146 | 146 | $elementTime = $currentTime - 86400 * 65; |
147 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
147 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
148 | 148 | |
149 | 149 | $this->assertEquals('2 months ago', $result); |
150 | 150 | |
151 | 151 | $elementTime = $currentTime - 86400 * 130; |
152 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
152 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
153 | 153 | |
154 | 154 | $this->assertEquals('4 months ago', $result); |
155 | 155 | } |
@@ -157,12 +157,12 @@ discard block |
||
157 | 157 | public function testRelativeDateLastYear(): void { |
158 | 158 | $currentTime = 1380703592; |
159 | 159 | $elementTime = $currentTime - 86400 * 365; |
160 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
160 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
161 | 161 | |
162 | 162 | $this->assertEquals('last year', $result); |
163 | 163 | |
164 | 164 | $elementTime = $currentTime - 86400 * 450; |
165 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
165 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
166 | 166 | |
167 | 167 | $this->assertEquals('last year', $result); |
168 | 168 | } |
@@ -170,12 +170,12 @@ discard block |
||
170 | 170 | public function testRelativeDateYearsAgo(): void { |
171 | 171 | $currentTime = 1380703592; |
172 | 172 | $elementTime = $currentTime - 86400 * 365.25 * 2; |
173 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
173 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
174 | 174 | |
175 | 175 | $this->assertEquals('2 years ago', $result); |
176 | 176 | |
177 | 177 | $elementTime = $currentTime - 86400 * 365.25 * 3; |
178 | - $result = (string)relative_modified_date($elementTime, $currentTime, true); |
|
178 | + $result = (string) relative_modified_date($elementTime, $currentTime, true); |
|
179 | 179 | |
180 | 180 | $this->assertEquals('3 years ago', $result); |
181 | 181 | } |
@@ -187,7 +187,7 @@ discard block |
||
187 | 187 | public function testRelativeTimeSecondsAgo(): void { |
188 | 188 | $currentTime = 1380703592; |
189 | 189 | $elementTime = $currentTime - 5; |
190 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
190 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
191 | 191 | |
192 | 192 | $this->assertEquals('seconds ago', $result); |
193 | 193 | } |
@@ -195,7 +195,7 @@ discard block |
||
195 | 195 | public function testRelativeTimeMinutesAgo(): void { |
196 | 196 | $currentTime = 1380703592; |
197 | 197 | $elementTime = $currentTime - 190; |
198 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
198 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
199 | 199 | |
200 | 200 | $this->assertEquals('3 minutes ago', $result); |
201 | 201 | } |
@@ -203,7 +203,7 @@ discard block |
||
203 | 203 | public function testRelativeTimeHoursAgo(): void { |
204 | 204 | $currentTime = 1380703592; |
205 | 205 | $elementTime = $currentTime - 7500; |
206 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
206 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
207 | 207 | |
208 | 208 | $this->assertEquals('2 hours ago', $result); |
209 | 209 | } |
@@ -211,13 +211,13 @@ discard block |
||
211 | 211 | public function testRelativeTime2DaysAgo(): void { |
212 | 212 | $currentTime = 1380703592; |
213 | 213 | $elementTime = $currentTime - 48 * 3600; |
214 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
214 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
215 | 215 | |
216 | 216 | $this->assertEquals('2 days ago', $result); |
217 | 217 | |
218 | 218 | // 2 days ago minus 4 hours is still 2 days ago |
219 | 219 | $elementTime = $currentTime - 52 * 3600; |
220 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
220 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
221 | 221 | |
222 | 222 | $this->assertEquals('2 days ago', $result); |
223 | 223 | } |
@@ -225,12 +225,12 @@ discard block |
||
225 | 225 | public function testRelativeTimeLastMonth(): void { |
226 | 226 | $currentTime = 1380703592; |
227 | 227 | $elementTime = $currentTime - 86400 * 31; |
228 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
228 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
229 | 229 | |
230 | 230 | $this->assertEquals('last month', $result); |
231 | 231 | |
232 | 232 | $elementTime = $currentTime - 86400 * 35; |
233 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
233 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
234 | 234 | |
235 | 235 | $this->assertEquals('last month', $result); |
236 | 236 | } |
@@ -238,12 +238,12 @@ discard block |
||
238 | 238 | public function testRelativeTimeMonthsAgo(): void { |
239 | 239 | $currentTime = 1380703592; |
240 | 240 | $elementTime = $currentTime - 86400 * 65; |
241 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
241 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
242 | 242 | |
243 | 243 | $this->assertEquals('2 months ago', $result); |
244 | 244 | |
245 | 245 | $elementTime = $currentTime - 86400 * 130; |
246 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
246 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
247 | 247 | |
248 | 248 | $this->assertEquals('4 months ago', $result); |
249 | 249 | } |
@@ -251,12 +251,12 @@ discard block |
||
251 | 251 | public function testRelativeTimeLastYear(): void { |
252 | 252 | $currentTime = 1380703592; |
253 | 253 | $elementTime = $currentTime - 86400 * 365; |
254 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
254 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
255 | 255 | |
256 | 256 | $this->assertEquals('last year', $result); |
257 | 257 | |
258 | 258 | $elementTime = $currentTime - 86400 * 450; |
259 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
259 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
260 | 260 | |
261 | 261 | $this->assertEquals('last year', $result); |
262 | 262 | } |
@@ -264,12 +264,12 @@ discard block |
||
264 | 264 | public function testRelativeTimeYearsAgo(): void { |
265 | 265 | $currentTime = 1380703592; |
266 | 266 | $elementTime = $currentTime - 86400 * 365.25 * 2; |
267 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
267 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
268 | 268 | |
269 | 269 | $this->assertEquals('2 years ago', $result); |
270 | 270 | |
271 | 271 | $elementTime = $currentTime - 86400 * 365.25 * 3; |
272 | - $result = (string)relative_modified_date($elementTime, $currentTime, false); |
|
272 | + $result = (string) relative_modified_date($elementTime, $currentTime, false); |
|
273 | 273 | |
274 | 274 | $this->assertEquals('3 years ago', $result); |
275 | 275 | } |
@@ -11,8 +11,8 @@ |
||
11 | 11 | |
12 | 12 | class TARTest extends TestBase { |
13 | 13 | protected function getExisting() { |
14 | - $dir = \OC::$SERVERROOT . '/tests/data'; |
|
15 | - return new TAR($dir . '/data.tar.gz'); |
|
14 | + $dir = \OC::$SERVERROOT.'/tests/data'; |
|
15 | + return new TAR($dir.'/data.tar.gz'); |
|
16 | 16 | } |
17 | 17 | |
18 | 18 | protected function getNew() { |
@@ -479,7 +479,7 @@ discard block |
||
479 | 479 | ->method('listCertificates'); |
480 | 480 | |
481 | 481 | $this->assertEquals([ |
482 | - 'verify' => \OC::$SERVERROOT . '/resources/config/ca-bundle.crt', |
|
482 | + 'verify' => \OC::$SERVERROOT.'/resources/config/ca-bundle.crt', |
|
483 | 483 | 'headers' => [ |
484 | 484 | 'User-Agent' => 'Nextcloud Server Crawler', |
485 | 485 | 'Accept-Encoding' => 'gzip', |
@@ -489,7 +489,7 @@ discard block |
||
489 | 489 | 'allow_local_address' => false, |
490 | 490 | ], |
491 | 491 | 'allow_redirects' => [ |
492 | - 'on_redirect' => function ( |
|
492 | + 'on_redirect' => function( |
|
493 | 493 | \Psr\Http\Message\RequestInterface $request, |
494 | 494 | \Psr\Http\Message\ResponseInterface $response, |
495 | 495 | \Psr\Http\Message\UriInterface $uri, |
@@ -548,7 +548,7 @@ discard block |
||
548 | 548 | 'allow_local_address' => false, |
549 | 549 | ], |
550 | 550 | 'allow_redirects' => [ |
551 | - 'on_redirect' => function ( |
|
551 | + 'on_redirect' => function( |
|
552 | 552 | \Psr\Http\Message\RequestInterface $request, |
553 | 553 | \Psr\Http\Message\ResponseInterface $response, |
554 | 554 | \Psr\Http\Message\UriInterface $uri, |
@@ -608,7 +608,7 @@ discard block |
||
608 | 608 | 'allow_local_address' => false, |
609 | 609 | ], |
610 | 610 | 'allow_redirects' => [ |
611 | - 'on_redirect' => function ( |
|
611 | + 'on_redirect' => function( |
|
612 | 612 | \Psr\Http\Message\RequestInterface $request, |
613 | 613 | \Psr\Http\Message\ResponseInterface $response, |
614 | 614 | \Psr\Http\Message\UriInterface $uri, |
@@ -717,7 +717,7 @@ discard block |
||
717 | 717 | $share2 = $this->provider->create($share); |
718 | 718 | |
719 | 719 | $this->assertNotNull($share2->getId()); |
720 | - $this->assertSame('ocinternal:' . $share2->getId(), $share2->getFullId()); |
|
720 | + $this->assertSame('ocinternal:'.$share2->getId(), $share2->getFullId()); |
|
721 | 721 | $this->assertSame(IShare::TYPE_USER, $share2->getShareType()); |
722 | 722 | $this->assertSame('sharedWith', $share2->getSharedWith()); |
723 | 723 | $this->assertSame('sharedBy', $share2->getSharedBy()); |
@@ -787,7 +787,7 @@ discard block |
||
787 | 787 | $share2 = $this->provider->create($share); |
788 | 788 | |
789 | 789 | $this->assertNotNull($share2->getId()); |
790 | - $this->assertSame('ocinternal:' . $share2->getId(), $share2->getFullId()); |
|
790 | + $this->assertSame('ocinternal:'.$share2->getId(), $share2->getFullId()); |
|
791 | 791 | $this->assertSame(IShare::TYPE_GROUP, $share2->getShareType()); |
792 | 792 | $this->assertSame('sharedWith', $share2->getSharedWith()); |
793 | 793 | $this->assertSame('sharedBy', $share2->getSharedBy()); |
@@ -856,7 +856,7 @@ discard block |
||
856 | 856 | $share2 = $this->provider->create($share); |
857 | 857 | |
858 | 858 | $this->assertNotNull($share2->getId()); |
859 | - $this->assertSame('ocinternal:' . $share2->getId(), $share2->getFullId()); |
|
859 | + $this->assertSame('ocinternal:'.$share2->getId(), $share2->getFullId()); |
|
860 | 860 | $this->assertSame(IShare::TYPE_LINK, $share2->getShareType()); |
861 | 861 | $this->assertSame('sharedBy', $share2->getSharedBy()); |
862 | 862 | $this->assertSame('shareOwner', $share2->getShareOwner()); |
@@ -1068,7 +1068,7 @@ discard block |
||
1068 | 1068 | |
1069 | 1069 | $groups = []; |
1070 | 1070 | foreach (range(0, 100) as $i) { |
1071 | - $groups[] = 'group' . $i; |
|
1071 | + $groups[] = 'group'.$i; |
|
1072 | 1072 | } |
1073 | 1073 | |
1074 | 1074 | $groups[] = 'sharedWith'; |
@@ -1187,7 +1187,7 @@ discard block |
||
1187 | 1187 | $this->assertCount(1, $share); |
1188 | 1188 | |
1189 | 1189 | $share = $share[0]; |
1190 | - $this->assertSame((string)$id, $share->getId()); |
|
1190 | + $this->assertSame((string) $id, $share->getId()); |
|
1191 | 1191 | $this->assertSame('sharedWith', $share->getSharedWith()); |
1192 | 1192 | $this->assertSame('shareOwner', $share->getShareOwner()); |
1193 | 1193 | $this->assertSame('sharedBy', $share->getSharedBy()); |
@@ -1322,7 +1322,7 @@ discard block |
||
1322 | 1322 | |
1323 | 1323 | $groups = []; |
1324 | 1324 | foreach (range(0, 100) as $i) { |
1325 | - $groups[] = 'group' . $i; |
|
1325 | + $groups[] = 'group'.$i; |
|
1326 | 1326 | } |
1327 | 1327 | |
1328 | 1328 | $groups[] = 'sharedWith'; |
@@ -1855,13 +1855,13 @@ discard block |
||
1855 | 1855 | $users = []; |
1856 | 1856 | for ($i = 0; $i < 6; $i++) { |
1857 | 1857 | $user = $this->createMock(IUser::class); |
1858 | - $user->method('getUID')->willReturn('user' . $i); |
|
1859 | - $user->method('getDisplayName')->willReturn('user' . $i); |
|
1860 | - $users['user' . $i] = $user; |
|
1858 | + $user->method('getUID')->willReturn('user'.$i); |
|
1859 | + $user->method('getDisplayName')->willReturn('user'.$i); |
|
1860 | + $users['user'.$i] = $user; |
|
1861 | 1861 | } |
1862 | 1862 | |
1863 | 1863 | $this->userManager->method('get')->willReturnCallback( |
1864 | - function ($userId) use ($users) { |
|
1864 | + function($userId) use ($users) { |
|
1865 | 1865 | return $users[$userId]; |
1866 | 1866 | } |
1867 | 1867 | ); |
@@ -1913,12 +1913,12 @@ discard block |
||
1913 | 1913 | $users = []; |
1914 | 1914 | for ($i = 0; $i < 6; $i++) { |
1915 | 1915 | $user = $this->createMock(IUser::class); |
1916 | - $user->method('getUID')->willReturn('user' . $i); |
|
1917 | - $users['user' . $i] = $user; |
|
1916 | + $user->method('getUID')->willReturn('user'.$i); |
|
1917 | + $users['user'.$i] = $user; |
|
1918 | 1918 | } |
1919 | 1919 | |
1920 | 1920 | $this->userManager->method('get')->willReturnCallback( |
1921 | - function ($userId) use ($users) { |
|
1921 | + function($userId) use ($users) { |
|
1922 | 1922 | return $users[$userId]; |
1923 | 1923 | } |
1924 | 1924 | ); |
@@ -1979,12 +1979,12 @@ discard block |
||
1979 | 1979 | $users = []; |
1980 | 1980 | for ($i = 0; $i < 6; $i++) { |
1981 | 1981 | $user = $this->createMock(IUser::class); |
1982 | - $user->method('getUID')->willReturn('user' . $i); |
|
1983 | - $users['user' . $i] = $user; |
|
1982 | + $user->method('getUID')->willReturn('user'.$i); |
|
1983 | + $users['user'.$i] = $user; |
|
1984 | 1984 | } |
1985 | 1985 | |
1986 | 1986 | $this->userManager->method('get')->willReturnCallback( |
1987 | - function ($userId) use ($users) { |
|
1987 | + function($userId) use ($users) { |
|
1988 | 1988 | return $users[$userId]; |
1989 | 1989 | } |
1990 | 1990 | ); |
@@ -2036,12 +2036,12 @@ discard block |
||
2036 | 2036 | $users = []; |
2037 | 2037 | for ($i = 0; $i < 6; $i++) { |
2038 | 2038 | $user = $this->createMock(IUser::class); |
2039 | - $user->method('getUID')->willReturn('user' . $i); |
|
2040 | - $users['user' . $i] = $user; |
|
2039 | + $user->method('getUID')->willReturn('user'.$i); |
|
2040 | + $users['user'.$i] = $user; |
|
2041 | 2041 | } |
2042 | 2042 | |
2043 | 2043 | $this->userManager->method('get')->willReturnCallback( |
2044 | - function ($userId) use ($users) { |
|
2044 | + function($userId) use ($users) { |
|
2045 | 2045 | return $users[$userId]; |
2046 | 2046 | } |
2047 | 2047 | ); |
@@ -2049,13 +2049,13 @@ discard block |
||
2049 | 2049 | $groups = []; |
2050 | 2050 | for ($i = 0; $i < 2; $i++) { |
2051 | 2051 | $group = $this->createMock(IGroup::class); |
2052 | - $group->method('getGID')->willReturn('group' . $i); |
|
2053 | - $group->method('getDisplayName')->willReturn('group-displayname' . $i); |
|
2054 | - $groups['group' . $i] = $group; |
|
2052 | + $group->method('getGID')->willReturn('group'.$i); |
|
2053 | + $group->method('getDisplayName')->willReturn('group-displayname'.$i); |
|
2054 | + $groups['group'.$i] = $group; |
|
2055 | 2055 | } |
2056 | 2056 | |
2057 | 2057 | $this->groupManager->method('get')->willReturnCallback( |
2058 | - function ($groupId) use ($groups) { |
|
2058 | + function($groupId) use ($groups) { |
|
2059 | 2059 | return $groups[$groupId]; |
2060 | 2060 | } |
2061 | 2061 | ); |
@@ -2115,12 +2115,12 @@ discard block |
||
2115 | 2115 | $users = []; |
2116 | 2116 | for ($i = 0; $i < 6; $i++) { |
2117 | 2117 | $user = $this->createMock(IUser::class); |
2118 | - $user->method('getUID')->willReturn('user' . $i); |
|
2119 | - $users['user' . $i] = $user; |
|
2118 | + $user->method('getUID')->willReturn('user'.$i); |
|
2119 | + $users['user'.$i] = $user; |
|
2120 | 2120 | } |
2121 | 2121 | |
2122 | 2122 | $this->userManager->method('get')->willReturnCallback( |
2123 | - function ($userId) use ($users) { |
|
2123 | + function($userId) use ($users) { |
|
2124 | 2124 | return $users[$userId]; |
2125 | 2125 | } |
2126 | 2126 | ); |
@@ -2128,13 +2128,13 @@ discard block |
||
2128 | 2128 | $groups = []; |
2129 | 2129 | for ($i = 0; $i < 2; $i++) { |
2130 | 2130 | $group = $this->createMock(IGroup::class); |
2131 | - $group->method('getGID')->willReturn('group' . $i); |
|
2132 | - $group->method('getDisplayName')->willReturn('group-displayname' . $i); |
|
2133 | - $groups['group' . $i] = $group; |
|
2131 | + $group->method('getGID')->willReturn('group'.$i); |
|
2132 | + $group->method('getDisplayName')->willReturn('group-displayname'.$i); |
|
2133 | + $groups['group'.$i] = $group; |
|
2134 | 2134 | } |
2135 | 2135 | |
2136 | 2136 | $this->groupManager->method('get')->willReturnCallback( |
2137 | - function ($groupId) use ($groups) { |
|
2137 | + function($groupId) use ($groups) { |
|
2138 | 2138 | return $groups[$groupId]; |
2139 | 2139 | } |
2140 | 2140 | ); |
@@ -2192,12 +2192,12 @@ discard block |
||
2192 | 2192 | $this->assertSame('user0', $shares[0]['share_with']); |
2193 | 2193 | $this->assertSame('user4', $shares[0]['uid_initiator']); |
2194 | 2194 | $this->assertSame('user5', $shares[0]['uid_owner']); |
2195 | - $this->assertSame(1, (int)$shares[0]['permissions']); |
|
2195 | + $this->assertSame(1, (int) $shares[0]['permissions']); |
|
2196 | 2196 | |
2197 | 2197 | $this->assertSame('user3', $shares[1]['share_with']); |
2198 | 2198 | $this->assertSame('user4', $shares[1]['uid_initiator']); |
2199 | 2199 | $this->assertSame('user5', $shares[1]['uid_owner']); |
2200 | - $this->assertSame(0, (int)$shares[1]['permissions']); |
|
2200 | + $this->assertSame(0, (int) $shares[1]['permissions']); |
|
2201 | 2201 | |
2202 | 2202 | |
2203 | 2203 | $stmt->closeCursor(); |