summaryrefslogtreecommitdiffstats
path: root/apps/dav/tests
diff options
context:
space:
mode:
authorChristopher Ng <chrng8@gmail.com>2022-02-23 05:27:49 +0000
committerChristopher Ng <chrng8@gmail.com>2022-03-02 01:59:15 +0000
commit302a67f6853065122ef8648cdbdefc1504e8d350 (patch)
treede3c6e69c8859252ebc3127d7f0831611c3251d9 /apps/dav/tests
parent4c3d68381b6bb1847a2b5b22dbfc61a83c529df6 (diff)
downloadnextcloud-server-302a67f6853065122ef8648cdbdefc1504e8d350.tar.gz
nextcloud-server-302a67f6853065122ef8648cdbdefc1504e8d350.zip
Integrate migrator
Signed-off-by: Christopher Ng <chrng8@gmail.com>
Diffstat (limited to 'apps/dav/tests')
-rw-r--r--apps/dav/tests/integration/UserMigration/CalendarMigratorTest.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/dav/tests/integration/UserMigration/CalendarMigratorTest.php b/apps/dav/tests/integration/UserMigration/CalendarMigratorTest.php
index 1f7bf630094..e2eb0c75d9b 100644
--- a/apps/dav/tests/integration/UserMigration/CalendarMigratorTest.php
+++ b/apps/dav/tests/integration/UserMigration/CalendarMigratorTest.php
@@ -97,7 +97,7 @@ class CalendarMigratorTest extends TestCase {
private function getSanitizedComponents(VCalendar $vCalendar): array {
return array_map(
// Elements of the serialized blob are sorted
- fn (VObjectComponent $component) => $this->migrator->sanitizeComponent($component)->serialize(),
+ fn (VObjectComponent $component) => $this->invokePrivate($this->migrator, 'sanitizeComponent', [$component])->serialize(),
$vCalendar->getComponents(),
);
}
@@ -111,9 +111,9 @@ class CalendarMigratorTest extends TestCase {
$problems = $importCalendar->validate();
$this->assertEmpty($problems);
- $this->migrator->importCalendar($user, $filename, $initialCalendarUri, $importCalendar);
+ $this->invokePrivate($this->migrator, 'importCalendar', [$user, $filename, $initialCalendarUri, $importCalendar]);
- $calendarExports = $this->migrator->getCalendarExports($user);
+ $calendarExports = $this->invokePrivate($this->migrator, 'getCalendarExports', [$user]);
$this->assertCount(1, $calendarExports);
/** @var VCalendar $exportCalendar */
@@ -125,7 +125,7 @@ class CalendarMigratorTest extends TestCase {
);
$this->assertEqualsCanonicalizing(
- // Components are sanitized on import
+ // Components are expected to be sanitized on import
$this->getSanitizedComponents($importCalendar),
$this->getComponents($exportCalendar),
);