Amazons3Test.php 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <?php
  2. /**
  3. * @copyright Copyright (c) 2016, ownCloud, Inc.
  4. *
  5. * @author Joas Schilling <coding@schilljs.com>
  6. * @author Michael Gapczynski <GapczynskiM@gmail.com>
  7. * @author Morris Jobke <hey@morrisjobke.de>
  8. * @author Robin Appelman <robin@icewind.nl>
  9. * @author Robin McCorkell <robin@mccorkell.me.uk>
  10. * @author Thomas Müller <thomas.mueller@tmit.eu>
  11. *
  12. * @license AGPL-3.0
  13. *
  14. * This code is free software: you can redistribute it and/or modify
  15. * it under the terms of the GNU Affero General Public License, version 3,
  16. * as published by the Free Software Foundation.
  17. *
  18. * This program is distributed in the hope that it will be useful,
  19. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  20. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  21. * GNU Affero General Public License for more details.
  22. *
  23. * You should have received a copy of the GNU Affero General Public License, version 3,
  24. * along with this program. If not, see <http://www.gnu.org/licenses/>
  25. *
  26. */
  27. namespace OCA\Files_External\Tests\Storage;
  28. use \OCA\Files_External\Lib\Storage\AmazonS3;
  29. /**
  30. * Class Amazons3Test
  31. *
  32. * @group DB
  33. *
  34. * @package OCA\Files_External\Tests\Storage
  35. */
  36. class Amazons3Test extends \Test\Files\Storage\Storage {
  37. private $config;
  38. protected function setUp() {
  39. parent::setUp();
  40. $this->config = include('files_external/tests/config.amazons3.php');
  41. if ( ! is_array($this->config) or ! $this->config['run']) {
  42. $this->markTestSkipped('AmazonS3 backend not configured');
  43. }
  44. $this->instance = new AmazonS3($this->config);
  45. }
  46. protected function tearDown() {
  47. if ($this->instance) {
  48. $this->instance->rmdir('');
  49. }
  50. parent::tearDown();
  51. }
  52. public function testStat() {
  53. $this->markTestSkipped('S3 doesn\'t update the parents folder mtime');
  54. }
  55. }