2012-05-16 21:51:45 -04:00
|
|
|
<?php
|
2025-05-17 05:46:26 -04:00
|
|
|
|
|
|
|
|
declare(strict_types=1);
|
2012-05-16 21:51:45 -04:00
|
|
|
/**
|
2024-06-06 03:55:47 -04:00
|
|
|
* SPDX-FileCopyrightText: 2019-2024 Nextcloud GmbH and Nextcloud contributors
|
|
|
|
|
* SPDX-FileCopyrightText: 2016 ownCloud, Inc.
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
2012-10-11 15:12:52 -04:00
|
|
|
*/
|
2016-04-13 18:18:07 -04:00
|
|
|
namespace OCA\Files_External\Tests\Storage;
|
|
|
|
|
|
2019-11-22 14:52:10 -05:00
|
|
|
use OCA\Files_External\Lib\Storage\AmazonS3;
|
2012-09-22 08:51:15 -04:00
|
|
|
|
2015-11-19 10:42:29 -05:00
|
|
|
/**
|
2016-05-24 10:37:06 -04:00
|
|
|
* Class Amazons3Test
|
2015-11-19 10:42:29 -05:00
|
|
|
*
|
|
|
|
|
*
|
2016-04-13 18:18:07 -04:00
|
|
|
* @package OCA\Files_External\Tests\Storage
|
2015-11-19 10:42:29 -05:00
|
|
|
*/
|
2026-01-07 08:21:48 -05:00
|
|
|
#[\PHPUnit\Framework\Attributes\Group(name: 'DB')]
|
2025-10-20 19:52:40 -04:00
|
|
|
#[\PHPUnit\Framework\Attributes\Group('S3')]
|
2016-05-24 10:37:06 -04:00
|
|
|
class Amazons3Test extends \Test\Files\Storage\Storage {
|
2025-09-26 03:39:33 -04:00
|
|
|
use ConfigurableStorageTrait;
|
2021-10-14 11:28:32 -04:00
|
|
|
/** @var AmazonS3 */
|
|
|
|
|
protected $instance;
|
2012-05-16 21:51:45 -04:00
|
|
|
|
2019-11-21 10:40:38 -05:00
|
|
|
protected function setUp(): void {
|
2014-11-10 16:28:12 -05:00
|
|
|
parent::setUp();
|
|
|
|
|
|
2025-12-18 10:10:06 -05:00
|
|
|
$this->loadConfig(__DIR__ . '/../config.amazons3.php');
|
2016-04-13 18:18:07 -04:00
|
|
|
$this->instance = new AmazonS3($this->config);
|
2012-10-11 15:12:52 -04:00
|
|
|
}
|
2012-05-16 21:51:45 -04:00
|
|
|
|
2019-11-21 10:40:38 -05:00
|
|
|
protected function tearDown(): void {
|
2012-10-11 15:12:52 -04:00
|
|
|
if ($this->instance) {
|
2014-08-01 08:20:00 -04:00
|
|
|
$this->instance->rmdir('');
|
2012-05-16 21:51:45 -04:00
|
|
|
}
|
2014-11-10 16:28:12 -05:00
|
|
|
|
|
|
|
|
parent::tearDown();
|
2012-05-16 21:51:45 -04:00
|
|
|
}
|
2014-08-01 09:06:05 -04:00
|
|
|
|
|
|
|
|
public function testStat(): void {
|
|
|
|
|
$this->markTestSkipped('S3 doesn\'t update the parents folder mtime');
|
|
|
|
|
}
|
2012-05-16 21:51:45 -04:00
|
|
|
}
|