diff options
author | John Molakvoæ <skjnldsv@users.noreply.github.com> | 2021-10-27 15:52:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-27 15:52:30 +0200 |
commit | cf58d5ff512a6af96f81c7911532fdcb176e6867 (patch) | |
tree | cdffbf3e484541c03becea0eedabaa4a8b1b3e9d /apps/files_external/tests/Storage/VersionedAmazonS3Test.php | |
parent | 799b77208e9544cd0a88e25ff90b6b7536673ef0 (diff) | |
parent | cf6da08f0093a9ade4a45a60dedba354f47f7394 (diff) | |
download | nextcloud-server-cf58d5ff512a6af96f81c7911532fdcb176e6867.tar.gz nextcloud-server-cf58d5ff512a6af96f81c7911532fdcb176e6867.zip |
Merge pull request #29447 from nextcloud/backport/29220/stable21
Diffstat (limited to 'apps/files_external/tests/Storage/VersionedAmazonS3Test.php')
-rw-r--r-- | apps/files_external/tests/Storage/VersionedAmazonS3Test.php | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/apps/files_external/tests/Storage/VersionedAmazonS3Test.php b/apps/files_external/tests/Storage/VersionedAmazonS3Test.php new file mode 100644 index 00000000000..a16a9944d57 --- /dev/null +++ b/apps/files_external/tests/Storage/VersionedAmazonS3Test.php @@ -0,0 +1,43 @@ +<?php + +declare(strict_types=1); +/** + * @copyright Copyright (c) 2021 Robin Appelman <robin@icewind.nl> + * + * @license GNU AGPL version 3 or any later version + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ + +namespace OCA\Files_External\Tests\Storage; + +/** + * @group DB + */ +class VersionedAmazonS3Test extends Amazons3Test { + protected function setUp(): void { + parent::setUp(); + try { + $this->instance->getConnection()->putBucketVersioning([ + 'Bucket' => $this->instance->getBucket(), + 'VersioningConfiguration' => [ + 'Status' => 'Enabled', + ], + ]); + } catch (\Exception $e) { + $this->markTestSkipped("s3 backend doesn't seem to support versioning"); + } + } +} |