2024-09-14 17:05:12 -04:00
|
|
|
<?php
|
2025-06-30 09:04:05 -04:00
|
|
|
|
2024-09-14 17:05:12 -04:00
|
|
|
/**
|
|
|
|
|
* SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
|
|
|
|
|
* SPDX-FileCopyrightText: 2016 ownCloud, Inc.
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
namespace Test\Files\ObjectStore;
|
|
|
|
|
|
2024-09-17 13:20:13 -04:00
|
|
|
use OC\Files\ObjectStore\StorageObjectStore;
|
|
|
|
|
use OC\Files\Storage\Temporary;
|
2025-06-30 10:56:59 -04:00
|
|
|
use OCP\Files\ObjectStore\IObjectStore;
|
2025-05-12 10:17:59 -04:00
|
|
|
use Test\Files\Storage\StoragesTestCase;
|
2024-09-14 17:05:12 -04:00
|
|
|
|
2025-10-20 19:52:40 -04:00
|
|
|
#[\PHPUnit\Framework\Attributes\Group('DB')]
|
2025-05-12 10:17:59 -04:00
|
|
|
class ObjectStoreStoragesSameBucketTest extends StoragesTestCase {
|
2024-09-14 17:05:12 -04:00
|
|
|
/**
|
2025-06-30 10:56:59 -04:00
|
|
|
* @var IObjectStore
|
2024-09-14 17:05:12 -04:00
|
|
|
*/
|
|
|
|
|
private $objectStore;
|
|
|
|
|
|
|
|
|
|
protected function setUp(): void {
|
|
|
|
|
parent::setUp();
|
|
|
|
|
|
|
|
|
|
$baseStorage = new Temporary();
|
|
|
|
|
$this->objectStore = new StorageObjectStore($baseStorage);
|
|
|
|
|
$config['objectstore'] = $this->objectStore;
|
|
|
|
|
// storage1 and storage2 share the same object store.
|
|
|
|
|
$this->storage1 = new ObjectStoreStorageOverwrite($config);
|
|
|
|
|
$this->storage2 = new ObjectStoreStorageOverwrite($config);
|
|
|
|
|
}
|
|
|
|
|
}
|