@@ -704,9 +704,9 @@ discard block |
||
704 | 704 | |
705 | 705 | $view->expects($this->any()) |
706 | 706 | ->method('file_exists') |
707 | - ->willReturnCallback(function ($path) use ($existingFiles, $folderPath) { |
|
707 | + ->willReturnCallback(function($path) use ($existingFiles, $folderPath) { |
|
708 | 708 | foreach ($existingFiles as $existing) { |
709 | - if ($folderPath . '/' . $existing === $path) { |
|
709 | + if ($folderPath.'/'.$existing === $path) { |
|
710 | 710 | return true; |
711 | 711 | } |
712 | 712 | } |
@@ -780,8 +780,8 @@ discard block |
||
780 | 780 | |
781 | 781 | |
782 | 782 | $nodes = $node->getRecent(5); |
783 | - $ids = array_map(function (Node $node) { |
|
784 | - return (int)$node->getId(); |
|
783 | + $ids = array_map(function(Node $node) { |
|
784 | + return (int) $node->getId(); |
|
785 | 785 | }, $nodes); |
786 | 786 | $this->assertEquals([$id1, $id2, $id3], $ids); |
787 | 787 | } |
@@ -845,8 +845,8 @@ discard block |
||
845 | 845 | |
846 | 846 | |
847 | 847 | $nodes = $node->getRecent(5); |
848 | - $ids = array_map(function (Node $node) { |
|
849 | - return (int)$node->getId(); |
|
848 | + $ids = array_map(function(Node $node) { |
|
849 | + return (int) $node->getId(); |
|
850 | 850 | }, $nodes); |
851 | 851 | $this->assertEquals([$id2, $id3], $ids); |
852 | 852 | $this->assertEquals($baseTime, $nodes[0]->getMTime()); |
@@ -904,8 +904,8 @@ discard block |
||
904 | 904 | $node = new Folder($root, $view, $folderPath, $folderInfo); |
905 | 905 | |
906 | 906 | $nodes = $node->getRecent(5); |
907 | - $ids = array_map(function (Node $node) { |
|
908 | - return (int)$node->getId(); |
|
907 | + $ids = array_map(function(Node $node) { |
|
908 | + return (int) $node->getId(); |
|
909 | 909 | }, $nodes); |
910 | 910 | $this->assertEquals([$id1], $ids); |
911 | 911 | } |
@@ -1032,7 +1032,7 @@ discard block |
||
1032 | 1032 | $cache->clear(); |
1033 | 1033 | $subCache1->clear(); |
1034 | 1034 | $subCache2->clear(); |
1035 | - $ids = array_map(function (Node $info) { |
|
1035 | + $ids = array_map(function(Node $info) { |
|
1036 | 1036 | return $info->getPath(); |
1037 | 1037 | }, $result); |
1038 | 1038 | $this->assertEquals($expectedPaths, $ids); |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | ], |
100 | 100 | [ |
101 | 101 | 'name' => 'Each day', |
102 | - 'value' => 60 * 24 . 'm' |
|
102 | + 'value' => 60 * 24.'m' |
|
103 | 103 | ], |
104 | 104 | ], |
105 | 105 | ], |
@@ -251,7 +251,7 @@ discard block |
||
251 | 251 | |
252 | 252 | $this->groupManager->expects($this->any()) |
253 | 253 | ->method('isAdmin') |
254 | - ->willReturnCallback(function ($userId) { |
|
254 | + ->willReturnCallback(function($userId) { |
|
255 | 255 | return $userId === 'admin_test_user'; |
256 | 256 | }); |
257 | 257 | } |
@@ -467,7 +467,7 @@ discard block |
||
467 | 467 | |
468 | 468 | $this->config->expects($this->any()) |
469 | 469 | ->method('getAppValue') |
470 | - ->willReturnCallback(function ($app, $configkey, $default) { |
|
470 | + ->willReturnCallback(function($app, $configkey, $default) { |
|
471 | 471 | if ($configkey === 'some_real_setting' && self::$testSetInternalValueAfterChange) { |
472 | 472 | return '120m'; |
473 | 473 | } |
@@ -54,11 +54,11 @@ |
||
54 | 54 | $ext = substr($target, $pos); |
55 | 55 | $append = ''; |
56 | 56 | $i = 1; |
57 | - while (in_array($name . $append . $ext, $knownTargets)) { |
|
57 | + while (in_array($name.$append.$ext, $knownTargets)) { |
|
58 | 58 | $append = $i; |
59 | 59 | $i++; |
60 | 60 | } |
61 | - $target = $name . $append . $ext; |
|
61 | + $target = $name.$append.$ext; |
|
62 | 62 | } |
63 | 63 | |
64 | 64 | return $target; |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | ['user1', 'http://server1', 'user1', 'http://server1', true], |
60 | 60 | ['user1', 'https://server1', 'user1', 'http://server1', true], |
61 | 61 | ['user1', 'http://serVer1', 'user1', 'http://server1', true], |
62 | - ['user1', 'http://server1/', 'user1', 'http://server1', true], |
|
62 | + ['user1', 'http://server1/', 'user1', 'http://server1', true], |
|
63 | 63 | ['user1', 'server1', 'user1', 'http://server1', true], |
64 | 64 | ['user1', 'http://server1', 'user1', 'http://server2', false], |
65 | 65 | ['user1', 'https://server1', 'user1', 'http://server2', false], |
@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | ['user1', 'http://server1', 'user2', 'http://server1', false], |
70 | 70 | ['user1', 'https://server1', 'user2', 'http://server1', false], |
71 | 71 | ['user1', 'http://serVer1', 'user2', 'http://server1', false], |
72 | - ['user1', 'http://server1/', 'user2', 'http://server1', false], |
|
72 | + ['user1', 'http://server1/', 'user2', 'http://server1', false], |
|
73 | 73 | ['user1', 'server1', 'user2', 'http://server1', false], |
74 | 74 | ]; |
75 | 75 | } |
@@ -54,7 +54,7 @@ |
||
54 | 54 | $this->logger = $this->createMock(LoggerInterface::class); |
55 | 55 | |
56 | 56 | $dbPrefix = $this->config->getSystemValueString('dbtableprefix'); |
57 | - $this->tableName = $this->getUniqueID($dbPrefix . '_collation_test'); |
|
57 | + $this->tableName = $this->getUniqueID($dbPrefix.'_collation_test'); |
|
58 | 58 | $this->connection->prepare("CREATE TABLE $this->tableName(text VARCHAR(16)) COLLATE utf8_unicode_ci")->execute(); |
59 | 59 | |
60 | 60 | $this->repair = new TestCollationRepair($this->config, $this->logger, $this->connection, false); |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | $shareResults = $this->createMock(IResult::class); |
112 | 112 | $shareResults->expects($this->any()) |
113 | 113 | ->method('fetch') |
114 | - ->willReturnCallback(function () use (&$shareResultData) { |
|
114 | + ->willReturnCallback(function() use (&$shareResultData) { |
|
115 | 115 | return array_pop($shareResultData); |
116 | 116 | }); |
117 | 117 | |
@@ -150,7 +150,7 @@ discard block |
||
150 | 150 | ->willReturnSelf(); |
151 | 151 | $updateMock->expects($this->exactly(4)) |
152 | 152 | ->method('setParameter') |
153 | - ->willReturnCallback(function () use (&$updateCalls, &$updateMock) { |
|
153 | + ->willReturnCallback(function() use (&$updateCalls, &$updateMock) { |
|
154 | 154 | $updateCalls[] = func_get_args(); |
155 | 155 | return $updateMock; |
156 | 156 | }); |
@@ -163,15 +163,15 @@ discard block |
||
163 | 163 | |
164 | 164 | $this->groupManager->expects($this->any()) |
165 | 165 | ->method('groupExists') |
166 | - ->willReturnCallback(function (string $gid) use ($existingGroups) { |
|
166 | + ->willReturnCallback(function(string $gid) use ($existingGroups) { |
|
167 | 167 | return in_array($gid, $existingGroups); |
168 | 168 | }); |
169 | 169 | |
170 | 170 | $this->repair->run($this->output); |
171 | 171 | self::assertEquals([ |
172 | - ['updatedPrincipalUri', 'principals/groups/' . urlencode('family friends'), null], |
|
172 | + ['updatedPrincipalUri', 'principals/groups/'.urlencode('family friends'), null], |
|
173 | 173 | ['shareId', 7, null], |
174 | - ['updatedPrincipalUri', 'principals/groups/' . urlencode('Wants Repair'), null], |
|
174 | + ['updatedPrincipalUri', 'principals/groups/'.urlencode('Wants Repair'), null], |
|
175 | 175 | ['shareId', 1, null] |
176 | 176 | ], $updateCalls); |
177 | 177 | } |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | $this->calendarEventBuilder->addAttendee('mailto:[email protected]'); |
46 | 46 | $this->calendarEventBuilder->addAttendee('mailto:[email protected]'); |
47 | 47 | |
48 | - $expected = file_get_contents(\OC::$SERVERROOT . '/tests/data/ics/event-builder-complete.ics'); |
|
48 | + $expected = file_get_contents(\OC::$SERVERROOT.'/tests/data/ics/event-builder-complete.ics'); |
|
49 | 49 | $actual = $this->calendarEventBuilder->toIcs(); |
50 | 50 | $this->assertEquals($expected, $actual); |
51 | 51 | } |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | $this->calendarEventBuilder->setSummary('My event'); |
58 | 58 | $this->calendarEventBuilder->setDescription('Foo bar baz'); |
59 | 59 | |
60 | - $expected = file_get_contents(\OC::$SERVERROOT . '/tests/data/ics/event-builder-without-attendees.ics'); |
|
60 | + $expected = file_get_contents(\OC::$SERVERROOT.'/tests/data/ics/event-builder-without-attendees.ics'); |
|
61 | 61 | $actual = $this->calendarEventBuilder->toIcs(); |
62 | 62 | $this->assertEquals($expected, $actual); |
63 | 63 | } |
@@ -72,7 +72,7 @@ discard block |
||
72 | 72 | $this->calendarEventBuilder->addAttendee('[email protected]'); |
73 | 73 | $this->calendarEventBuilder->addAttendee('[email protected]'); |
74 | 74 | |
75 | - $expected = file_get_contents(\OC::$SERVERROOT . '/tests/data/ics/event-builder-complete.ics'); |
|
75 | + $expected = file_get_contents(\OC::$SERVERROOT.'/tests/data/ics/event-builder-complete.ics'); |
|
76 | 76 | $actual = $this->calendarEventBuilder->toIcs(); |
77 | 77 | $this->assertEquals($expected, $actual); |
78 | 78 | } |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | $this->calendarEventBuilder->addAttendee('[email protected]'); |
88 | 88 | $this->calendarEventBuilder->addAttendee('mailto:[email protected]'); |
89 | 89 | |
90 | - $expectedIcs = file_get_contents(\OC::$SERVERROOT . '/tests/data/ics/event-builder-complete.ics'); |
|
90 | + $expectedIcs = file_get_contents(\OC::$SERVERROOT.'/tests/data/ics/event-builder-complete.ics'); |
|
91 | 91 | $calendar = $this->createMock(ICreateFromString::class); |
92 | 92 | $calendar->expects(self::once()) |
93 | 93 | ->method('createFromString') |
@@ -54,8 +54,8 @@ discard block |
||
54 | 54 | $this->server->expects(self::exactly(2)) |
55 | 55 | ->method('query') |
56 | 56 | ->willReturnMap([ |
57 | - ['calendar_room_backend1', true, $backend1,], |
|
58 | - ['calendar_room_backend2', true, $backend2,], |
|
57 | + ['calendar_room_backend1', true, $backend1, ], |
|
58 | + ['calendar_room_backend2', true, $backend2, ], |
|
59 | 59 | ]); |
60 | 60 | |
61 | 61 | $this->manager->registerBackend('calendar_room_backend1'); |
@@ -101,8 +101,8 @@ discard block |
||
101 | 101 | $this->server->expects(self::exactly(2)) |
102 | 102 | ->method('query') |
103 | 103 | ->willReturnMap([ |
104 | - ['calendar_room_backend1', true, $backend1,], |
|
105 | - ['calendar_room_backend2', true, $backend2,], |
|
104 | + ['calendar_room_backend1', true, $backend1, ], |
|
105 | + ['calendar_room_backend2', true, $backend2, ], |
|
106 | 106 | ]); |
107 | 107 | |
108 | 108 | $this->manager->registerBackend('calendar_room_backend1'); |
@@ -120,8 +120,8 @@ discard block |
||
120 | 120 | $this->server->expects(self::exactly(2)) |
121 | 121 | ->method('query') |
122 | 122 | ->willReturnMap([ |
123 | - ['calendar_room_backend1', true, $backend1,], |
|
124 | - ['calendar_room_backend2', true, $backend2,], |
|
123 | + ['calendar_room_backend1', true, $backend1, ], |
|
124 | + ['calendar_room_backend2', true, $backend2, ], |
|
125 | 125 | ]); |
126 | 126 | |
127 | 127 | $this->manager->registerBackend('calendar_room_backend1'); |
@@ -54,8 +54,8 @@ discard block |
||
54 | 54 | $this->server->expects(self::exactly(2)) |
55 | 55 | ->method('query') |
56 | 56 | ->willReturnMap([ |
57 | - ['calendar_resource_backend1', true, $backend1,], |
|
58 | - ['calendar_resource_backend2', true, $backend2,], |
|
57 | + ['calendar_resource_backend1', true, $backend1, ], |
|
58 | + ['calendar_resource_backend2', true, $backend2, ], |
|
59 | 59 | ]); |
60 | 60 | |
61 | 61 | $this->manager->registerBackend('calendar_resource_backend1'); |
@@ -99,8 +99,8 @@ discard block |
||
99 | 99 | $this->server->expects(self::exactly(2)) |
100 | 100 | ->method('query') |
101 | 101 | ->willReturnMap([ |
102 | - ['calendar_resource_backend1', true, $backend1,], |
|
103 | - ['calendar_resource_backend2', true, $backend2,], |
|
102 | + ['calendar_resource_backend1', true, $backend1, ], |
|
103 | + ['calendar_resource_backend2', true, $backend2, ], |
|
104 | 104 | ]); |
105 | 105 | |
106 | 106 | $this->manager->registerBackend('calendar_resource_backend1'); |
@@ -118,8 +118,8 @@ discard block |
||
118 | 118 | $this->server->expects(self::exactly(2)) |
119 | 119 | ->method('query') |
120 | 120 | ->willReturnMap([ |
121 | - ['calendar_resource_backend1', true, $backend1,], |
|
122 | - ['calendar_resource_backend2', true, $backend2,], |
|
121 | + ['calendar_resource_backend1', true, $backend1, ], |
|
122 | + ['calendar_resource_backend2', true, $backend2, ], |
|
123 | 123 | ]); |
124 | 124 | |
125 | 125 | $this->manager->registerBackend('calendar_resource_backend1'); |